mirror of
https://github.com/getgrav/grav.git
synced 2025-02-20 19:56:53 +01:00
missed a check in MediaUploadTrait::checkFileMetadata()
This commit is contained in:
parent
ee8d783d05
commit
77adfcb831
|
|
@ -5,6 +5,7 @@
|
|||
* Better handling of external protocols in `Utils::url()` such as `mailto:`, `tel:`, etc.
|
||||
1. [](#bugfix)
|
||||
* Fixes for multi-lang taxonomy when reinitializing the languages (e.g. LangSwitcher plugin)
|
||||
* Ensure the full filepath is checked for invalid filename in `Utils::checkFileMetadata()`
|
||||
|
||||
# v1.7.45
|
||||
## 03/18/2024
|
||||
|
|
|
|||
|
|
@ -156,7 +156,7 @@ trait MediaUploadTrait
|
|||
$filepath = $folder . $filename;
|
||||
|
||||
// Check if the filename is allowed.
|
||||
if (!Utils::checkFilename($filename)) {
|
||||
if (!Utils::checkFilename($filepath)) {
|
||||
throw new RuntimeException(
|
||||
sprintf($this->translate('PLUGIN_ADMIN.FILEUPLOAD_UNABLE_TO_UPLOAD'), $filepath, $this->translate('PLUGIN_ADMIN.BAD_FILENAME'))
|
||||
);
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user