Skip to content

Commit 070b7de

Browse files
committed
Adapt to new clean-css script path
1 parent adba1e2 commit 070b7de

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

src/NodejsPhpFallback/Uglify.php

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,8 @@ class Uglify extends Wrapper
1111
protected $concat = array();
1212

1313
protected $programs = array(
14-
'js' => 'uglify',
15-
'css' => 'clean',
14+
'js' => array('uglify-js/bin/', 'uglifyjs'),
15+
'css' => array('clean-css/', 'index.js'),
1616
);
1717

1818
public function __construct($file)
@@ -87,15 +87,15 @@ public function write($path)
8787
public function compile()
8888
{
8989
$language = $this->getMode();
90-
$program = $this->programs[$language];
90+
list($programDirectory, $programFile) = $this->programs[$language];
9191
$name = $this->path ? basename($this->path) : null;
9292

9393
$path = sys_get_temp_dir() . DIRECTORY_SEPARATOR . $name;
9494
file_put_contents($path, $this->getSource());
9595

9696
return $this->execModuleScript(
97-
$program . '-' . $language,
98-
'bin/' . $program . $language,
97+
$programDirectory,
98+
$programFile,
9999
escapeshellarg($path)
100100
);
101101
}

0 commit comments

Comments
 (0)