Skip to content

Commit

Permalink
Link to the libgit2 issue.
Browse files Browse the repository at this point in the history
  • Loading branch information
joshaber committed Jan 19, 2016
1 parent 514842c commit 50c7449
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions src/git-repository-async.js
Original file line number Diff line number Diff line change
Expand Up @@ -862,10 +862,9 @@ export default class GitRepositoryAsync {
try {
await repo.refreshStatus()
} catch (e) {
// If we error trying to refresh, then it probably means the submodule
// isn't actually a submodule. Libgit2 will report anything listed in
// .gitmodules as a submodule, but that's not necessarily accurate. So
// get rid of the submodule entry.
// libgit2 will sometimes report submodules that aren't actually valid
// (https://github.com/libgit2/libgit2/issues/3580). So check the
// validity of the submodules by removing any that fail.
repo.destroy()
delete this.submodules[name]
}
Expand Down

0 comments on commit 50c7449

Please sign in to comment.