From b6c6cc3dcf7c16fa01b9198a1403f2a0a4cb81a6 Mon Sep 17 00:00:00 2001 From: Alexander Ebert Date: Sat, 24 Oct 2015 20:24:58 +0200 Subject: [PATCH] Fixed style compiler --- .../files/lib/system/style/StyleCompiler.class.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/wcfsetup/install/files/lib/system/style/StyleCompiler.class.php b/wcfsetup/install/files/lib/system/style/StyleCompiler.class.php index 09d47bfa9e..b728974a52 100644 --- a/wcfsetup/install/files/lib/system/style/StyleCompiler.class.php +++ b/wcfsetup/install/files/lib/system/style/StyleCompiler.class.php @@ -52,7 +52,7 @@ class StyleCompiler extends SingletonFactory { public function compile(Style $style) { // read stylesheets by dependency order $conditions = new PreparedStatementConditionBuilder(); - $conditions->add("filename REGEXP ?", ['style/([a-zA-Z0-9\_\-\.]+)\.(less|scss)']); + $conditions->add("filename REGEXP ?", ['style/([a-zA-Z0-9\_\-\.]+)\.scss']); // TESTING ONLY $conditions->add("packageID <> ?", [1]); @@ -77,7 +77,7 @@ class StyleCompiler extends SingletonFactory { $file = WCF_DIR."style/{$file}/"; if ($innerHandle = opendir($file)) { while (($innerFile = readdir($innerHandle)) !== false) { - if ($innerFile === '.' || $innerFile === '..' || !is_file($file.$innerFile) || preg_match('~\.less$~', $innerFile)) { + if ($innerFile === '.' || $innerFile === '..' || !is_file($file.$innerFile) || !preg_match('~^[a-zA-Z]+\.scss~$', $innerFile)) { continue; } @@ -139,7 +139,7 @@ class StyleCompiler extends SingletonFactory { public function compileACP() { // read stylesheets by dependency order $conditions = new PreparedStatementConditionBuilder(); - $conditions->add("filename REGEXP ?", ['style/([a-zA-Z0-9\_\-\.]+)\.(less|scss)']); + $conditions->add("filename REGEXP ?", ['style/([a-zA-Z0-9\_\-\.]+)\.scss']); // TESTING ONLY $conditions->add("packageID <> ?", [1]); @@ -164,7 +164,7 @@ class StyleCompiler extends SingletonFactory { $file = WCF_DIR."style/{$file}/"; if ($innerHandle = opendir($file)) { while (($innerFile = readdir($innerHandle)) !== false) { - if ($innerFile === '.' || $innerFile === '..' || !is_file($file.$innerFile) || preg_match('~\.less$~', $innerFile)) { + if ($innerFile === '.' || $innerFile === '..' || !is_file($file.$innerFile) || !preg_match('~^[a-zA-Z]+\.scss~$', $innerFile)) { continue; } -- 2.20.1