Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

core/commands/add: Change add() to only accept a single reader #1127

Merged
merged 2 commits into from
Apr 27, 2015

Commits on Apr 23, 2015

  1. core/commands/add: Change add() to only accept a single reader

    The change to an array of readers comes from e096060
    (refactor(core/commands2/add) split loop, 2014-11-06), where it's used
    to setup readers for each path in the argument list.  However, since
    6faeee8 (cmds2/add: temp fix for -r. horrible hack, 2014-11-11) the
    argument looping moved outside of add() and into Run(), so we can drop
    the multiple-reader support from add().
    
    Adding a file can create multiple nodes (e.g. the splitter can chunk
    the file into several blocks), but:
    
    1. we were only appending a single node per reader to our returned
       list, and
    2. we are only using the final node in that returned list,
    
    so this commit also adjusts add() to return a single node reference
    instead on an array of nodes.
    wking committed Apr 23, 2015
    Configuration menu
    Copy the full SHA
    c322a4e View commit details
    Browse the repository at this point in the history
  2. core/coreunixs/add: Change add() to only accept a single reader

    Catch up with core/commands/add.go.
    wking committed Apr 23, 2015
    Configuration menu
    Copy the full SHA
    641c20b View commit details
    Browse the repository at this point in the history