From a54bb44ec8bc12d66afbab495b1998ff2d4cd727 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Florian=20Kr=C3=A4mer?= Date: Thu, 12 Mar 2015 23:48:52 +0100 Subject: [PATCH] #127 BC fix to support Jsqueeze 1.x and 2.x --- src/Task/Assets/Minify.php | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/Task/Assets/Minify.php b/src/Task/Assets/Minify.php index 399ff14e2..53e5adf20 100644 --- a/src/Task/Assets/Minify.php +++ b/src/Task/Assets/Minify.php @@ -155,7 +155,11 @@ protected function getMinifiedText() break; case 'js': - $jsqueeze = new \JSqueeze(); + if (class_exists('\JSqueeze')) { + $jsqueeze = new \JSqueeze(); + } else { + $jsqueeze = new \Patchwork\JSqueeze(); + } return $jsqueeze->squeeze( $this->text, $this->squeezeOptions['singleLine'],