summaryrefslogtreecommitdiff
path: root/lib/readline.js
diff options
context:
space:
mode:
authorKyle Robinson Young <kyle@dontkry.com>2012-04-18 12:37:54 -0700
committerBen Noordhuis <info@bnoordhuis.nl>2012-04-18 21:57:39 +0200
commit57148f54e10f57a15deb51713bbe70f5f126b4dc (patch)
treeeafc6b3b9f6b3926471c255bc4451aac93003a64 /lib/readline.js
parentc56d1559fc45375283cc9a616abf73b2e453d77e (diff)
downloadnodejs-57148f54e10f57a15deb51713bbe70f5f126b4dc.tar.gz
nodejs-57148f54e10f57a15deb51713bbe70f5f126b4dc.tar.bz2
nodejs-57148f54e10f57a15deb51713bbe70f5f126b4dc.zip
readline: change char to ch to avoid reserved word
Diffstat (limited to 'lib/readline.js')
-rw-r--r--lib/readline.js8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/readline.js b/lib/readline.js
index 75eb7fe08..d69aeb4a8 100644
--- a/lib/readline.js
+++ b/lib/readline.js
@@ -839,7 +839,7 @@ var functionKeyCodeRe =
/^(?:\x1b+)(O|N|\[|\[\[)(?:(\d+)(?:;(\d+))?([~^$])|(?:1;)?(\d+)?([a-zA-Z]))/;
function emitKey(stream, s) {
- var char,
+ var ch,
key = {
name: undefined,
ctrl: false,
@@ -1029,11 +1029,11 @@ function emitKey(stream, s) {
}
if (s.length === 1) {
- char = s;
+ ch = s;
}
- if (key || char) {
- stream.emit('keypress', char, key);
+ if (key || ch) {
+ stream.emit('keypress', ch, key);
}
}