diff --git a/src/Common/Upload.php b/src/Common/Upload.php index 5fba7cd23..7d217da3d 100644 --- a/src/Common/Upload.php +++ b/src/Common/Upload.php @@ -190,7 +190,7 @@ class Upload } // Check extension - if ($uploaded_only && (!isset($this->ext_ids[$this->file_ext]) || !\in_array($this->file_ext, $this->cfg['allowed_ext'], true))) { + if ($uploaded_only && (!isset($this->ext_ids[$this->file_ext]) || !in_array($this->file_ext, $this->cfg['allowed_ext'], true))) { $this->errors[] = sprintf($lang['UPLOAD_ERROR_NOT_ALLOWED'], htmlCHR($this->file_ext)); return false; } @@ -231,7 +231,7 @@ class Upload */ public function _move($file_path) { - $dir = \dirname($file_path); + $dir = dirname($file_path); if (!file_exists($dir)) { if (!bb_mkdir($dir)) { $this->errors[] = "Cannot create dir: $dir";