From 319d019768871d2363a11dd5d71d898f7393a5b8 Mon Sep 17 00:00:00 2001 From: Labhansh Agrawal Date: Wed, 7 Apr 2021 15:40:20 +0530 Subject: [PATCH] Remove usage of String.replaceAll It works in electron, but it's not part of ES2020 --- app/session.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/session.ts b/app/session.ts index 9858213e..dcbcba2c 100644 --- a/app/session.ts +++ b/app/session.ts @@ -187,7 +187,7 @@ please check the shell config: ${JSON.stringify({shell, shellArgs}, undefined, 2 fallback to default shell config: ${JSON.stringify(defaultShellConfig, undefined, 2)} `; console.warn(msg); - this.batcher?.write(msg.replaceAll('\n', '\r\n') as any); + this.batcher?.write(msg.replace(/\n/g, '\r\n') as any); this.init({uid, rows, cols: columns, cwd, ...defaultShellConfig}); } else { this.ended = true;