From 8029293d30bd3bdad7a549994afdd47fbc7160cb Mon Sep 17 00:00:00 2001 From: Brian Miyaji Date: Thu, 31 Mar 2016 12:31:32 +1100 Subject: [PATCH] Display default caption for combined player stats --- templates/player-statistics.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/templates/player-statistics.php b/templates/player-statistics.php index 060ae606..d48f0e1b 100644 --- a/templates/player-statistics.php +++ b/templates/player-statistics.php @@ -39,14 +39,16 @@ if ( is_array( $leagues ) ): if ( -1 !== $section_id && ! in_array( $section_id, $player_sections ) ) continue; foreach ( $leagues as $league ): + $caption = $league->name; + if ( null !== $section_label ) { if ( sizeof( $leagues ) > 1 ) { printf( '

%s

', $section_label ); - $caption = $league->name; } else { $caption = $section_label; } } + sp_get_template( 'player-statistics-league.php', array( 'data' => $player->data( $league->term_id, false, $section_id ), 'league' => $league,