diff --git a/lib/readline.js b/lib/readline.js index 036a36249588cf..bde2e7016b9388 100644 --- a/lib/readline.js +++ b/lib/readline.js @@ -483,7 +483,7 @@ Interface.prototype._tabComplete = function(lastKeypressWasTab) { maxColumns = 1; } var group = []; - for (var i = 0, compLen = completions.length; i < compLen; i++) { + for (var i = 0; i < completions.length; i++) { var c = completions[i]; if (c === '') { handleGroup(self, group, width, maxColumns); @@ -522,7 +522,7 @@ function handleGroup(self, group, width, maxColumns) { var item = group[idx]; self._writeToOutput(item); if (col < maxColumns - 1) { - for (var s = 0, itemLen = item.length; s < width - itemLen; s++) { + for (var s = 0; s < width - item.length; s++) { self._writeToOutput(' '); } }