Skip to content

Commit 13d3155

Browse files
committed
PHPStan fix
1 parent fa2545f commit 13d3155

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/DB_Command.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1319,7 +1319,7 @@ public function status( $_, $assoc_args ) {
13191319
if ( ! empty( $db_size_bytes ) && $db_size_bytes > 0 ) {
13201320
$size_key = floor( log( (float) $db_size_bytes ) / log( 1000 ) );
13211321
$sizes = [ 'B', 'KB', 'MB', 'GB', 'TB' ];
1322-
$size_format = $sizes[ $size_key ] ?? $sizes[0];
1322+
$size_format = $sizes[ (int) $size_key ] ?? $sizes[0];
13231323
$divisor = pow( 1000, $size_key );
13241324
$db_size = round( (int) $db_size_bytes / $divisor, 2 ) . ' ' . $size_format;
13251325
} else {

0 commit comments

Comments
 (0)