diff --git a/templates/countdown.php b/templates/countdown.php index 692235c5..24594de3 100644 --- a/templates/countdown.php +++ b/templates/countdown.php @@ -46,13 +46,15 @@ if ( $link_events ) $title = '' . get_the_post_thumbnail( $team, 'sportspress-fit-icon' ) . ''; - } else { - echo get_the_post_thumbnail( $team, 'sportspress-fit-icon', array( 'class' => 'team-logo logo-' . ( $i % 2 ? 'odd' : 'even' ) ) ); + if ( is_array( $teams ) ) { + foreach ( $teams as $team ) { + $i++; + if ( has_post_thumbnail ( $team ) ) { + if ( $link_teams ) { + echo ''; + } else { + echo get_the_post_thumbnail( $team, 'sportspress-fit-icon', array( 'class' => 'team-logo logo-' . ( $i % 2 ? 'odd' : 'even' ) ) ); + } } } }