Skip to content

Commit

Permalink
Rename \Aurora\System\Helper::getPHPSize method to getPhpSize
Browse files Browse the repository at this point in the history
  • Loading branch information
Usbac committed Jan 28, 2024
1 parent 050bcde commit fcc271d
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion app/controllers/Media.php
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,7 @@ public static function uploadFile($file, string $path): bool
*/
public static function getMaxUploadFileSize(): mixed
{
return min(array_map(fn($key) => \Aurora\System\Helper::getPHPSize(ini_get($key)), [ 'post_max_size', 'upload_max_filesize' ]));
return min(array_map(fn($key) => \Aurora\System\Helper::getPhpSize(ini_get($key)), [ 'post_max_size', 'upload_max_filesize' ]));
}

/**
Expand Down
2 changes: 1 addition & 1 deletion app/views/admin/settings.php
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@
</div>
<div class="input-group">
<label><?= t('memory_limit') ?></label>
<span><?= e(\Aurora\System\Helper::getByteSize(\Aurora\System\Helper::getPHPSize(ini_get('memory_limit')))) ?></span>
<span><?= e(\Aurora\System\Helper::getByteSize(\Aurora\System\Helper::getPhpSize(ini_get('memory_limit')))) ?></span>
</div>
<div class="input-group">
<label><?= t('file_size_upload_limit') ?></label>
Expand Down
2 changes: 1 addition & 1 deletion system/Helper.php
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ public static function getByteSize(float $bytes): string
* @param string $size_str The PHP size string
* @return int the size in bytes
*/
public static function getPHPSize(string $size_str): int
public static function getPhpSize(string $size_str): int
{
$size = substr($size_str, 0, -1);
switch (strtoupper(substr($size_str, -1))) {
Expand Down

0 comments on commit fcc271d

Please sign in to comment.