mirror of
https://github.com/monstra-cms/monstra.git
synced 2025-07-31 02:10:37 +02:00
Fix Number.php: Undefined offset
This commit is contained in:
@@ -44,7 +44,7 @@ class Number
|
||||
|
||||
$unit = array('b', 'kb', 'mb', 'gb', 'tb', 'pb');
|
||||
|
||||
return @round($size/pow(1024, ($i=floor(log($size, 1024)))), 2).' '.$unit[$i];
|
||||
return @round($size/pow(1024, ($i=floor(log($size, 1024)))), 2).' '.$unit[($i < 0 ? 0 : $i)];
|
||||
}
|
||||
|
||||
/**
|
||||
|
Reference in New Issue
Block a user