From b4728f6aa4e220d94a379047a3bb4b2416b511dd Mon Sep 17 00:00:00 2001 From: Korenevskiy Denis Date: Fri, 24 Nov 2017 17:52:46 +0300 Subject: [PATCH] set deactivated terminal handlers to empty functions instead of null this allows to avoid console spamming with 'not a function' messages after the connection to server was closed. --- js/src/hterm.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/js/src/hterm.ts b/js/src/hterm.ts index 8863f12..b49a22f 100644 --- a/js/src/hterm.ts +++ b/js/src/hterm.ts @@ -75,9 +75,9 @@ export class Hterm { }; deactivate(): void { - this.io.onVTKeystroke = null; - this.io.sendString = null - this.io.onTerminalResize = null; + this.io.onVTKeystroke = function(){}; + this.io.sendString = function(){}; + this.io.onTerminalResize = function(){}; this.term.uninstallKeyboard(); }