Skip to content

Commit

Permalink
fix merge
Browse files Browse the repository at this point in the history
  • Loading branch information
kirawi committed Apr 9, 2024
1 parent 846eb2c commit 802db6f
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion helix-core/src/history.rs
Original file line number Diff line number Diff line change
Expand Up @@ -293,7 +293,10 @@ impl History {
NonZeroUsize::new(other.revisions.len());
other.revisions.push(r);
}
self.current += offset;

if self.current >= n {
self.current += offset;
}
self.revisions = other.revisions;

Ok(())
Expand Down

0 comments on commit 802db6f

Please sign in to comment.