mirror of
https://github.com/monstra-cms/monstra.git
synced 2025-08-03 11:47:51 +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');
|
$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