summaryrefslogtreecommitdiff
path: root/lib/readline.js
diff options
context:
space:
mode:
Diffstat (limited to 'lib/readline.js')
-rw-r--r--lib/readline.js5
1 files changed, 2 insertions, 3 deletions
diff --git a/lib/readline.js b/lib/readline.js
index b5dab31a5f..5237b258ed 100644
--- a/lib/readline.js
+++ b/lib/readline.js
@@ -392,9 +392,8 @@ Interface.prototype._normalWrite = function(b) {
// either '' or (conceivably) the unfinished portion of the next line
string = lines.pop();
this._line_buffer = string;
- lines.forEach(function(line) {
- this._onLine(line);
- }, this);
+ for (var n = 0; n < lines.length; n++)
+ this._onLine(lines[n]);
} else if (string) {
// no newlines this time, save what we have for next time
this._line_buffer = string;