aboutsummaryrefslogtreecommitdiff
path: root/helix-term/src
diff options
context:
space:
mode:
authorGraic2022-10-12 13:34:35 +0000
committerGitHub2022-10-12 13:34:35 +0000
commit68909dcef46c7b68f1a92cdc7fd04eb89549b6fb (patch)
tree5c7ee95e3f7f56006d7435907823d40cb89bbbd6 /helix-term/src
parentc54a0363bb59300290efa8ba86e291d94f938673 (diff)
Fix append cursor location when selection anchor is at end of document (#4147)
Diffstat (limited to 'helix-term/src')
-rw-r--r--helix-term/src/commands.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/helix-term/src/commands.rs b/helix-term/src/commands.rs
index ad84c85c..474006e3 100644
--- a/helix-term/src/commands.rs
+++ b/helix-term/src/commands.rs
@@ -2222,7 +2222,7 @@ fn append_mode(cx: &mut Context) {
.iter()
.last()
.expect("selection should always have at least one range");
- if !last_range.is_empty() && last_range.head == end {
+ if !last_range.is_empty() && last_range.to() == end {
let transaction = Transaction::change(
doc.text(),
[(end, end, Some(doc.line_ending.as_str().into()))].into_iter(),