From 9e182a625548ce369ae7f42bf576c8c4f06f82d0 Mon Sep 17 00:00:00 2001 From: Steve Clay Date: Thu, 4 Jan 2024 00:25:09 -0500 Subject: [PATCH] Use scssphp/scssphp --- composer.json | 2 +- lib/Minify/ScssCssSource.php | 7 +++---- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/composer.json b/composer.json index 4e3d874..221fdd7 100644 --- a/composer.json +++ b/composer.json @@ -44,9 +44,9 @@ }, "require-dev": { "firephp/firephp-core": "~0.4.0", - "leafo/scssphp": "^0.3 || ^0.6 || ^0.7", "meenie/javascript-packer": "~1.1", "phpunit/phpunit": "^8", + "scssphp/scssphp": "^1.12", "tedivm/jshrink": "~1.1.0" }, "suggest": { diff --git a/lib/Minify/ScssCssSource.php b/lib/Minify/ScssCssSource.php index 1ec9e73..7a6312f 100644 --- a/lib/Minify/ScssCssSource.php +++ b/lib/Minify/ScssCssSource.php @@ -1,7 +1,6 @@ setImportPaths(dirname($filename)); - $css = $scss->compile(file_get_contents($filename), $filename); + $css = $scss->compileString(file_get_contents($filename), $filename)->getCss(); $elapsed = round((microtime(true) - $start), 4); $v = Version::VERSION;