diff --git a/lib/readline.js b/lib/readline.js index d3245615566..947daddaddc 100644 --- a/lib/readline.js +++ b/lib/readline.js @@ -470,8 +470,8 @@ Interface.prototype._tabComplete = function(lastKeypressWasTab) { } // If there is a common prefix to all matches, then apply that portion. - const f = completions.filter(function(e) { if (e) return e; }); - const prefix = commonPrefix(f); + var f = completions.filter(function(e) { if (e) return e; }); + var prefix = commonPrefix(f); if (prefix.length > completeOn.length) { self._insertString(prefix.slice(completeOn.length)); }