« get me outta code hell

Make isEnter work with normal terminals - tui-lib - Pure Node.js library for making visual command-line programs (ala vim, ncdu)
about summary refs log tree commit diff
diff options
context:
space:
mode:
authorFlorrie <towerofnix@gmail.com>2017-12-08 12:12:56 -0400
committerFlorrie <towerofnix@gmail.com>2017-12-08 12:12:56 -0400
commitdbdf9cc8f4dbc138766bf8b0ea756cbe6fd6ba32 (patch)
tree0bb320c794f4105100dbc36fc37849420cd3b6cd
parent1a0a5e16f303d6450b1a9762a5e3298a124489c9 (diff)
Make isEnter work with normal terminals
-rw-r--r--util/telchars.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/util/telchars.js b/util/telchars.js
index 7f4d8e4..6908600 100644
--- a/util/telchars.js
+++ b/util/telchars.js
@@ -6,7 +6,7 @@ const compareBufStr = (buf, str) => {
 
 const telchars = {
   isSpace: buf => buf[0] === 0x20,
-  isEnter: buf => buf[0] === 0x0d && buf[1] === 0x00,
+  isEnter: buf => buf[0] === 0x0d,
   isTab: buf => buf[0] === 0x09,
   isBackTab: buf => buf[0] === 0x1b && buf[2] === 0x5A,
   isBackspace: buf => buf[0] === 0x7F,