Should always be array

This commit is contained in:
Brian Miyaji
2017-01-08 11:02:42 +11:00
parent 0960bd7c3c
commit 6dfa5063ff

View File

@@ -13,7 +13,7 @@ if ( get_option( 'sportspress_event_show_logos', 'yes' ) === 'no' ) return;
if ( ! isset( $id ) )
$id = get_the_ID();
$teams = get_post_meta( $id, 'sp_team' );
$teams = (array) get_post_meta( $id, 'sp_team' );
$teams = array_filter( $teams, 'sp_filter_positive' );
if ( ! $teams ) return;