FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

Potential example issue in add-and-commit.js L45-48 · Issue #409 · nodegit/nodegit · GitHub

Repository navigation

Potential example issue in add-and-commit.js L45-48 #409

Description

At line 45 of https://github.com/nodegit/nodegit/blob/master/examples/add-and-commit.js#L45 the sample calls return index.addByPath(fileName); line 48 then calls the same method but with the directory name as well: return index.addByPath(path.join(directoryName, fileName));

Should l45 be removed? They feel redundant, and in the case that you're working with a subdirectory and similarly named files (like index.html), it's possible that this code could actually add two different fles to the index...

No activity

Activity on this issue will appear here.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions


      Back | FazBrowse Home | New Git URL