|
@ -34,9 +34,7 @@ export class DiffWithWorkingCommand extends ActiveEditorCommand { |
|
|
// If the sha is missing, just let the user know the file matches
|
|
|
// If the sha is missing, just let the user know the file matches
|
|
|
if (gitUri.sha === undefined) return window.showInformationMessage('File matches the working tree'); |
|
|
if (gitUri.sha === undefined) return window.showInformationMessage('File matches the working tree'); |
|
|
if (gitUri.sha === GitService.deletedOrMissingSha) { |
|
|
if (gitUri.sha === GitService.deletedOrMissingSha) { |
|
|
return window.showInformationMessage( |
|
|
|
|
|
'Unable to open compare. File has been deleted from the working tree' |
|
|
|
|
|
); |
|
|
|
|
|
|
|
|
return window.showWarningMessage('Unable to open compare. File has been deleted from the working tree'); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
// If we are a fake "staged" sha, check the status
|
|
|
// If we are a fake "staged" sha, check the status
|
|
@ -84,7 +82,7 @@ export class DiffWithWorkingCommand extends ActiveEditorCommand { |
|
|
|
|
|
|
|
|
const [workingFileName] = await Container.git.findWorkingFileName(gitUri.fsPath, gitUri.repoPath); |
|
|
const [workingFileName] = await Container.git.findWorkingFileName(gitUri.fsPath, gitUri.repoPath); |
|
|
if (workingFileName === undefined) { |
|
|
if (workingFileName === undefined) { |
|
|
return window.showInformationMessage('Unable to open compare. File has been deleted from the working tree'); |
|
|
|
|
|
|
|
|
return window.showWarningMessage('Unable to open compare. File has been deleted from the working tree'); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
args.commit.workingFileName = workingFileName; |
|
|
args.commit.workingFileName = workingFileName; |
|
|