aboutsummaryrefslogtreecommitdiff
path: root/helix-term/src/ui/prompt.rs
diff options
context:
space:
mode:
authorBlaž Hrastnik2022-01-06 02:03:54 +0000
committerBlaž Hrastnik2022-01-06 02:03:54 +0000
commit3e4f81547c679619c96d0a6477ebf1d3badfe661 (patch)
tree3e8791650c4c31864f88a026259bf35a0410dbcd /helix-term/src/ui/prompt.rs
parentb18bda928f0c7889031ec0327b9468280dbc3791 (diff)
fix: Use std::path::MAIN_SEPARATOR to determine completion
Refs #1439
Diffstat (limited to 'helix-term/src/ui/prompt.rs')
-rw-r--r--helix-term/src/ui/prompt.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/helix-term/src/ui/prompt.rs b/helix-term/src/ui/prompt.rs
index 29e0339a..0202de23 100644
--- a/helix-term/src/ui/prompt.rs
+++ b/helix-term/src/ui/prompt.rs
@@ -473,7 +473,7 @@ impl Component for Prompt {
}
}
key!(Enter) => {
- if self.selection.is_some() && self.line.ends_with('/') {
+ if self.selection.is_some() && self.line.ends_with(std::path::MAIN_SEPARATOR) {
self.completion = (self.completion_fn)(&self.line);
self.exit_selection();
} else {