Browse Source

Changes getCommit to return 1st commit

main
Eric Amodio 5 years ago
parent
commit
508f597972
1 changed files with 1 additions and 1 deletions
  1. +1
    -1
      src/git/gitService.ts

+ 1
- 1
src/git/gitService.ts View File

@ -1126,7 +1126,7 @@ export class GitService implements Disposable {
const log = await this.getLog(repoPath, { maxCount: 2, ref: ref });
if (log === undefined) return undefined;
return log.commits.get(ref);
return log.commits.get(ref) || Iterables.first(log.commits.values());
}
@log()

Loading…
Cancel
Save