Complete move from old repository to new repository structure!

This commit is contained in:
Dane Everitt 2017-08-26 18:08:11 -05:00
parent 2cabb61b54
commit 72735c24f7
No known key found for this signature in database
GPG key ID: EEA66103B3D71F53
27 changed files with 964 additions and 730 deletions

View file

@ -32,6 +32,16 @@ if (! function_exists('human_readable')) {
*/
function human_readable($path, $precision = 2)
{
if (is_numeric($path)) {
$i = 0;
while (($path / 1024) > 0.9) {
$path = $path / 1024;
++$i;
}
return round($path, $precision) . ['B', 'kB', 'MB', 'GB', 'TB', 'PB', 'EB', 'ZB', 'YB'][$i];
}
return app('file')->humanReadableSize($path, $precision);
}
}