Prevent total time from displaying as 0:00 in box score

This commit is contained in:
Brian Miyaji
2017-01-16 12:03:27 +11:00
parent 765f10bf6e
commit 30ce7d1dc2

View File

@@ -107,6 +107,14 @@ if ( ! isset( $subs ) ) $subs = array();
$format = sp_array_value( $formats, $key, 'number' );
$placeholder = sp_get_format_placeholder( $format );
if ( ! array_key_exists( $key, $totals ) ):
$totals[ $key ] = $placeholder;
endif;
if ( 'time' === $format ):
$totals[ $key ] = ' ';
endif;
$value = '-';
if ( $key == 'position' ):
@@ -133,10 +141,6 @@ if ( ! isset( $subs ) ) $subs = array();
else:
$value = $placeholder;
endif;
if ( ! array_key_exists( $key, $totals ) ):
$totals[ $key ] = $placeholder;
endif;
if ( 'number' === $format ):
$value = floatval( $value );