mirror of
https://github.com/yiisoft/yii2.git
synced 2025-11-08 08:56:23 +08:00
#3807: Wrong js/css path composition at AssetController::buildTarget() fixed
This commit is contained in:
@ -302,9 +302,10 @@ class AssetController extends Controller
|
|||||||
$this->compressCssFiles($inputFiles, $tempFile);
|
$this->compressCssFiles($inputFiles, $tempFile);
|
||||||
}
|
}
|
||||||
|
|
||||||
$outputFile = $target->basePath . '/' . strtr($target->$type, ['{hash}' => md5_file($tempFile)]);
|
$targetFile = strtr($target->$type, ['{hash}' => md5_file($tempFile)]);
|
||||||
|
$outputFile = $target->basePath . '/' . $targetFile;
|
||||||
rename($tempFile, $outputFile);
|
rename($tempFile, $outputFile);
|
||||||
$target->$type = [$outputFile];
|
$target->$type = [$targetFile];
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
Reference in New Issue
Block a user