From 1a4b3d61e5b5e5148909d0764257b40e9d7e39b1 Mon Sep 17 00:00:00 2001 From: Eric Amodio Date: Thu, 4 Jan 2018 01:42:16 -0500 Subject: [PATCH] Adds explicit skipMerges to match diffWithPrevious --- src/commands/diffWithNext.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/commands/diffWithNext.ts b/src/commands/diffWithNext.ts index ab746b5..3a7f07b 100644 --- a/src/commands/diffWithNext.ts +++ b/src/commands/diffWithNext.ts @@ -42,7 +42,7 @@ export class DiffWithNextCommand extends ActiveEditorCommand { // If we are a fake "staged" sha, treat it as a DiffWithWorking if (GitService.isStagedUncommitted(sha!)) return commands.executeCommand(Commands.DiffWithWorking, uri); - const log = await this.git.getLogForFile(gitUri.repoPath, gitUri.fsPath, { maxCount: sha !== undefined ? undefined : 2, range: args.range! }); + const log = await this.git.getLogForFile(gitUri.repoPath, gitUri.fsPath, { maxCount: sha !== undefined ? undefined : 2, range: args.range!, skipMerges: true }); if (log === undefined) return Messages.showFileNotUnderSourceControlWarningMessage('Unable to open compare'); args.commit = (sha && log.commits.get(sha)) || Iterables.first(log.commits.values());