Fix obsolete, now erroneous type-casting of used memory size to string

for calling human_filesize

phpcs-errors:226 phpunit-status:successful
This commit is contained in:
Joshua Ramon Enslin 2020-08-11 13:39:47 +02:00 committed by Stefan Rohde-Enslin
parent 11c63fc58e
commit 76b5069b15
3 changed files with 3 additions and 4 deletions

@ -1 +1 @@
Subproject commit 08c9582210be11ba211d012e8aea2838fd1e9909
Subproject commit b8d8be54b9a21945be4a9396b6065ac4cc940deb

View File

@ -77,7 +77,7 @@ function mdErrorHandler(int $errno, string $string, string $file, int $line):voi
$errorMsg = "*$errno (<a href='https://www.google.de/search?q=php+" . str_replace(" ", "+", $string) . "'>$string</a>) at $file: line_ $line _";
$errorMsg .= $userMsg;
$errorMsg .= " |-- Error generating page: <a href='$errorPageFull'>$errorPage</a>";
$errorMsg .= " |-- Used RAM / Peak RAM / Allowed: " . MD_STD::human_filesize((string)memory_get_usage()) . " / " . MD_STD::human_filesize((string)memory_get_peak_usage()) . " / " . ini_get("memory_limit");
$errorMsg .= " |-- Used RAM / Peak RAM / Allowed: " . MD_STD::human_filesize(memory_get_usage()) . " / " . MD_STD::human_filesize(memory_get_peak_usage()) . " / " . ini_get("memory_limit");
$errorMsg = str_replace(PHP_EOL, " ", $errorMsg);

View File

@ -2,8 +2,7 @@
declare(strict_types = 1);
require_once __DIR__ . "/functions/functions.php";
$target = "csv/";
$target .= basename($_FILES['uploaded']['name']);
$target = "csv/" . basename($_FILES['uploaded']['name']);
$targetpart = basename($_FILES['uploaded']['name']);
if (session_status() != PHP_SESSION_ACTIVE) {