From d9f67742908062e636bb45a73d04ae5c55d64a39 Mon Sep 17 00:00:00 2001 From: Brian Miyaji Date: Thu, 23 Oct 2014 13:28:26 +1100 Subject: [PATCH] Skip adding logos to event if not available --- templates/event-logos.php | 1 + 1 file changed, 1 insertion(+) diff --git a/templates/event-logos.php b/templates/event-logos.php index 875f390c..eff49850 100644 --- a/templates/event-logos.php +++ b/templates/event-logos.php @@ -18,6 +18,7 @@ $teams = array_filter( $teams ); if ( $teams ): $team_logos = array(); foreach ( $teams as $team ): + if ( ! has_post_thumbnail( $team ) ) continue; $logo = get_the_post_thumbnail( $team, 'sportspress-fit-icon' ); if ( get_option( 'sportspress_link_teams', 'no' ) == 'yes' ) $logo = '' . $logo . ''; $team_logos[] = $logo;