Update some button...unsure of what it does

This commit is contained in:
Adithya1996 2022-03-11 12:07:07 +05:30
parent 99a461304f
commit 32d65660eb

View file

@ -57,9 +57,10 @@ fitAddon.fit();
window.onmessage = function(e) {
if (e.data === 'hello') {
// alert('It works!');
socket.emit("data", "ls\r");
const commandWithPrefix = `${e.data}`;
if (commandWithPrefix.substring(0,13) === "dt_ui_command") {
let command = commandWithPrefix.replace("dt_ui_command ", '');
socket.emit("data", `${command}\r`);
}
};