Skip to content

Commit

Permalink
Fix issue where the completionEscape parameter is not used for tab co…
Browse files Browse the repository at this point in the history
…mpletions when autocompleteMenu is true
  • Loading branch information
jpaye committed Mar 23, 2023
1 parent cf6746e commit a7ed99f
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion js/autocomplete_menu.js
Expand Up @@ -105,7 +105,7 @@
}
}
if (e.which === 9) {
if (term.complete(matched)) {
if (term.complete(matched, {escape: completionEscape})) {
word = term.before_cursor(true);
regex = new RegExp('^' + $.terminal.escape_regex(word));
}
Expand All @@ -126,6 +126,7 @@
var onInit = settings.onInit || $.noop;
var keydown = settings.keydown || $.noop;
var completion = settings.completion;
var completionEscape = settings.completionEscape;
delete settings.completion;
settings.onInit = function(term) {
onInit.call(this, term);
Expand Down

0 comments on commit a7ed99f

Please sign in to comment.