showing storage size refactoring

This commit is contained in:
Čarodej
2021-12-17 11:23:02 +01:00
parent afb8323541
commit 401b511b40
5 changed files with 53 additions and 22 deletions

View File

@@ -461,13 +461,13 @@ if (! function_exists('get_storage_fill_percentage')) {
* Get storage usage in percent
*
* @param $used
* @param $capacity
* @param $from
* @return string
*/
function get_storage_fill_percentage($used, $capacity)
function get_storage_fill_percentage($used, $from)
{
// Format gigabytes to bytes
$total = intval(Metric::gigabytes($capacity)->numberOfBytes());
$total = intval(Metric::gigabytes($from)->numberOfBytes());
// Count progress
if ($total == 0) {