Skip to content

Commit 08baa8a

Browse files
authored
Git - Only use this.dotGit when resolving HEAD (microsoft#165497)
Fix microsoft#164363
1 parent 7acbd9d commit 08baa8a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

extensions/git/src/git.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2067,7 +2067,7 @@ export class Repository {
20672067
}
20682068

20692069
async getHEADFS(): Promise<Ref> {
2070-
const raw = await fs.readFile(path.join(this.dotGit.commonPath ?? this.dotGit.path, 'HEAD'), 'utf8');
2070+
const raw = await fs.readFile(path.join(this.dotGit.path, 'HEAD'), 'utf8');
20712071

20722072
// Branch
20732073
const branchMatch = raw.match(/^ref: refs\/heads\/(?<name>.*)$/m);

0 commit comments

Comments
 (0)