Fix errors

This commit is contained in:
Art4 2024-12-07 22:08:59 +00:00
parent 43c71412e4
commit 82ed43f507
3 changed files with 9 additions and 10 deletions

View file

@ -77,10 +77,10 @@ class qqFileUploader {
public function __construct(array $allowedExtensions = [], $sizeLimit = 10485760)
{
$allowedExtensions = array_map('strtolower', $allowedExtensions);
$this->allowedExtensions = $allowedExtensions;
$this->sizeLimit = $sizeLimit;
$this->checkServerSettings();
if (isset($_GET['qqfile'])) {
@ -88,7 +88,7 @@ class qqFileUploader {
} elseif (isset($_FILES['qqfile'])) {
$this->file = new qqUploadedFileForm();
} else {
$this->file = false;
$this->file = false;
}
}
@ -105,7 +105,7 @@ class qqFileUploader {
private function toBytes(string $str): int
{
$val = trim($str);
$val = (int) trim($str);
$last = strtolower($str[strlen($str) - 1]);
switch($last) {