mirror of
https://github.com/Combodo/iTop.git
synced 2026-04-24 02:58:43 +02:00
N°5122 - Update libs to new PHP requirements
This commit is contained in:
@@ -223,8 +223,8 @@ class UploadedFile extends File
|
||||
*/
|
||||
public static function getMaxFilesize()
|
||||
{
|
||||
$sizePostMax = self::parseFilesize(ini_get('post_max_size'));
|
||||
$sizeUploadMax = self::parseFilesize(ini_get('upload_max_filesize'));
|
||||
$sizePostMax = self::parseFilesize(\ini_get('post_max_size'));
|
||||
$sizeUploadMax = self::parseFilesize(\ini_get('upload_max_filesize'));
|
||||
|
||||
return min($sizePostMax ?: \PHP_INT_MAX, $sizeUploadMax ?: \PHP_INT_MAX);
|
||||
}
|
||||
@@ -253,8 +253,11 @@ class UploadedFile extends File
|
||||
|
||||
switch (substr($size, -1)) {
|
||||
case 't': $max *= 1024;
|
||||
// no break
|
||||
case 'g': $max *= 1024;
|
||||
// no break
|
||||
case 'm': $max *= 1024;
|
||||
// no break
|
||||
case 'k': $max *= 1024;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user