mirror of
https://github.com/ckaczor/vscode-gitlens.git
synced 2026-02-16 10:58:34 -05:00
Switches to use repoPath on GitService
This commit is contained in:
@@ -8,7 +8,7 @@ import { copy } from 'copy-paste';
|
||||
|
||||
export class CopyShaToClipboardCommand extends ActiveEditorCommand {
|
||||
|
||||
constructor(private git: GitService, private repoPath: string) {
|
||||
constructor(private git: GitService) {
|
||||
super(Commands.CopyShaToClipboard);
|
||||
}
|
||||
|
||||
@@ -20,7 +20,7 @@ export class CopyShaToClipboardCommand extends ActiveEditorCommand {
|
||||
try {
|
||||
// If we don't have an editor then get the sha of the last commit to the branch
|
||||
if (!uri) {
|
||||
const log = await this.git.getLogForRepo(this.repoPath, undefined, 1);
|
||||
const log = await this.git.getLogForRepo(this.git.repoPath, undefined, 1);
|
||||
if (!log) return undefined;
|
||||
|
||||
sha = Iterables.first(log.commits.values()).sha;
|
||||
|
||||
Reference in New Issue
Block a user