Skip to content

Commit 6c36dcc

Browse files
committed
made changes requested by review
1 parent b9d8ddd commit 6c36dcc

File tree

2 files changed

+4
-5
lines changed

2 files changed

+4
-5
lines changed

src/model.ts

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,6 @@ export class GitExtension implements IGitExtension, IDisposable {
8989

9090
if (change.newValue !== change.oldValue) {
9191
this.refresh().then(() => this._repositoryChanged.emit(change));
92-
this._repositoryChanged.emit(change);
9392
}
9493
})
9594
.catch(reason => {
@@ -337,7 +336,7 @@ export class GitExtension implements IGitExtension, IDisposable {
337336
}
338337

339338
/** Refresh the git repository status */
340-
async _refreshStatus(): Promise<void> {
339+
protected async _refreshStatus(): Promise<void> {
341340
await this.ready;
342341
const path = this.pathRepository;
343342

@@ -422,7 +421,7 @@ export class GitExtension implements IGitExtension, IDisposable {
422421
}
423422

424423
/** Make request for a list of all git branches in the repository */
425-
async _branch(): Promise<Git.IBranchResult> {
424+
protected async _branch(): Promise<Git.IBranchResult> {
426425
await this.ready;
427426
const path = this.pathRepository;
428427

src/utils.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ export function extractFilename(path: string): string {
3131
}
3232
}
3333

34-
export function decodeStage(x: string, y: string) {
34+
export function decodeStage(x: string, y: string): string | null {
3535
// If file is untracked
3636
if (x === '?' && y === '?') {
3737
return 'untracked';
@@ -46,7 +46,7 @@ export function decodeStage(x: string, y: string) {
4646
}
4747
}
4848

49-
return undefined;
49+
return null;
5050
}
5151

5252
/** Open a file in the git listing */

0 commit comments

Comments
 (0)