Skip to content

Commit 4978e1e

Browse files
committed
Fixes #1204 - files comparison was backwards
1 parent 25086de commit 4978e1e

File tree

3 files changed

+9
-3
lines changed

3 files changed

+9
-3
lines changed

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,12 @@ All notable changes to this project will be documented in this file.
44

55
The format is based on [Keep a Changelog](http://keepachangelog.com/) and this project adheres to [Semantic Versioning](http://semver.org/).
66

7+
## [Unreleased]
8+
9+
### Fixed
10+
11+
- Fixes [#1204](https://github.com/eamodio/vscode-gitlens/issues/1204) - Compare file changes: "new" and "old" sides of the compare are backwards
12+
713
## [11.0.4] - 2020-11-22
814

915
### Fixed

src/views/nodes/compareBranchNode.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -119,8 +119,8 @@ export class CompareBranchNode extends ViewNode<BranchesView | CommitsView | Rep
119119
this.view,
120120
this,
121121
this.uri.repoPath!,
122-
this.branch.ref,
123-
this.compareWithWorkingTree ? '' : this._compareWith.ref || 'HEAD',
122+
this._compareWith.ref || 'HEAD',
123+
this.compareWithWorkingTree ? '' : this.branch.ref,
124124
this.getFilesQuery.bind(this),
125125
undefined,
126126
{

src/views/nodes/compareResultsNode.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -125,8 +125,8 @@ export class CompareResultsNode extends ViewNode<SearchAndCompareView> {
125125
this.view,
126126
this,
127127
this.uri.repoPath!,
128-
this._ref.ref,
129128
this._compareWith.ref,
129+
this._ref.ref,
130130
this.getFilesQuery.bind(this),
131131
undefined,
132132
{

0 commit comments

Comments
 (0)