mirror of
https://github.com/yiisoft/yii2.git
synced 2025-11-02 13:02:24 +08:00
Fix #16658: Fix file readability check on publishing assets by yii\web\AssetManager
This commit is contained in:
@ -4,6 +4,7 @@ Yii Framework 2 Change Log
|
|||||||
2.0.47 under development
|
2.0.47 under development
|
||||||
------------------------
|
------------------------
|
||||||
|
|
||||||
|
- Bug #16658: Fix file readability check on publishing assets by `yii\web\AssetManager` (manchenkoff)
|
||||||
- Bug #15557: Fix empty fields exclusion in safe attributes of `yii\base\Model` (manchenkoff)
|
- Bug #15557: Fix empty fields exclusion in safe attributes of `yii\base\Model` (manchenkoff)
|
||||||
- Bug #19508: Fix wrong selection for boolean attributes in GridView (alnidok)
|
- Bug #19508: Fix wrong selection for boolean attributes in GridView (alnidok)
|
||||||
- Bug #19517: Fix regression in `CompositeAuth::authenticate()` introduced in #19418 (WinterSilence)
|
- Bug #19517: Fix regression in `CompositeAuth::authenticate()` introduced in #19418 (WinterSilence)
|
||||||
|
|||||||
@ -476,6 +476,10 @@ class AssetManager extends Component
|
|||||||
throw new InvalidArgumentException("The file or directory to be published does not exist: $path");
|
throw new InvalidArgumentException("The file or directory to be published does not exist: $path");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (!is_readable($path)) {
|
||||||
|
throw new InvalidArgumentException("The file or directory to be published is not readable: $path");
|
||||||
|
}
|
||||||
|
|
||||||
if (is_file($src)) {
|
if (is_file($src)) {
|
||||||
return $this->_published[$path] = $this->publishFile($src);
|
return $this->_published[$path] = $this->publishFile($src);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user