From 0f05ecbbc635d003c0270cfe2677b86760c203d0 Mon Sep 17 00:00:00 2001 From: Toby Zerner Date: Wed, 14 Nov 2018 06:45:14 +1030 Subject: [PATCH] Fix incorrect regex modifier, causing JS to become malformed is some cases --- framework/core/src/Frontend/Compiler/JsCompiler.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/framework/core/src/Frontend/Compiler/JsCompiler.php b/framework/core/src/Frontend/Compiler/JsCompiler.php index 9bf5719e6..b86a42044 100644 --- a/framework/core/src/Frontend/Compiler/JsCompiler.php +++ b/framework/core/src/Frontend/Compiler/JsCompiler.php @@ -67,7 +67,7 @@ class JsCompiler extends RevisionCompiler */ protected function format(string $string): string { - return preg_replace('~//# sourceMappingURL.*$~s', '', $string).";\n"; + return preg_replace('~//# sourceMappingURL.*$~m', '', $string).";\n"; } /**