From 909f9f862ee50ad0dcadd6667dd3c494a81dc091 Mon Sep 17 00:00:00 2001 From: Ylian Saint-Hilaire Date: Tue, 25 Oct 2022 09:58:04 -0700 Subject: [PATCH] Fixed SSH with xterm.js (#4668) --- views/default.handlebars | 4 +++- views/ssh.handlebars | 10 ++++------ 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/views/default.handlebars b/views/default.handlebars index 4d0c96c6..4d71cd1a 100644 --- a/views/default.handlebars +++ b/views/default.handlebars @@ -10190,7 +10190,9 @@ case 'sessionerror': { p12setConsoleMsg("Session expired", 5000); break; } case 'sessiontimeout': { p12setConsoleMsg("Session timeout", 5000); break; } } - } else if (data[0] == '~') { xterm.writeUtf8(data.substring(1)); } + } else if (data[0] == '~') { + if (xterm.writeUtf8) { xterm.writeUtf8(data.substring(1)); } else { xterm.write(data.substring(1)); } + } } } diff --git a/views/ssh.handlebars b/views/ssh.handlebars index 407e0489..e3924656 100644 --- a/views/ssh.handlebars +++ b/views/ssh.handlebars @@ -37,14 +37,12 @@ -
+
-
-
-
-
+
+