Skip to content
This repository has been archived by the owner on Jun 26, 2020. It is now read-only.

Commit

Permalink
Fix: Fixed CC drop in .sort comparing function.
Browse files Browse the repository at this point in the history
  • Loading branch information
scofalik committed Oct 24, 2018
1 parent 3dc4052 commit 623280d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/model/differ.js
Original file line number Diff line number Diff line change
Expand Up @@ -423,7 +423,7 @@ export default class Differ {
// If change happens at the same position...
if ( a.position.isEqual( b.position ) ) {
// Keep chronological order of operations.
return a.changeCount < b.changeCount ? -1 : 1;
return a.changeCount - b.changeCount;
}

// If positions differ, position "on the left" should be earlier in the result.
Expand Down

0 comments on commit 623280d

Please sign in to comment.