From 9b3e596baec469c282f16d96e16e7117bd9e9bcd Mon Sep 17 00:00:00 2001 From: mxd <838425805@qq.com> Date: Sun, 5 Sep 2021 18:45:33 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BB=A3=E7=A0=81=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- magic-editor/src/console/src/scripts/beautifier/core/output.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/magic-editor/src/console/src/scripts/beautifier/core/output.js b/magic-editor/src/console/src/scripts/beautifier/core/output.js index 4a569423..5d9db8a6 100644 --- a/magic-editor/src/console/src/scripts/beautifier/core/output.js +++ b/magic-editor/src/console/src/scripts/beautifier/core/output.js @@ -311,7 +311,7 @@ Output.prototype.get_code = function(eol) { var sweet_code = this.__lines.join('\n'); if (eol === '\r\n') { - sweet_code = sweet_code.replaceAll(/([^\r])\n/g, `$1${eol}`); + sweet_code = sweet_code.replace(/([^\r])\n/g, `$1${eol}`); }else if (eol !== '\n') { sweet_code = sweet_code.replace(/[\n]/g, eol); }