diff --git a/src/NodejsPhpFallback/Uglify.php b/src/NodejsPhpFallback/Uglify.php index beb348c..ac03981 100644 --- a/src/NodejsPhpFallback/Uglify.php +++ b/src/NodejsPhpFallback/Uglify.php @@ -88,7 +88,8 @@ public function compile() { $language = $this->getMode(); list($programDirectory, $programFile) = $this->programs[$language]; - $name = $this->path ? basename($this->path) : null; + $path = $this->getPath(); + $name = $path ? basename($path) : null; $path = sys_get_temp_dir() . DIRECTORY_SEPARATOR . $name; file_put_contents($path, $this->getSource());