Make is_sportspress dependant on post types

This commit is contained in:
Brian Miyaji
2014-05-30 18:27:04 +10:00
parent ab95b0facc
commit 2f97cfb7d3
2 changed files with 2 additions and 2 deletions

View File

@@ -19,7 +19,7 @@ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
* @return bool
*/
function is_sportspress() {
return apply_filters( 'is_sportspress', ( is_singular( array( 'sp_event', 'sp_calendar', 'sp_team', 'sp_table', 'sp_player', 'sp_list', 'sp_staff' ) ) ) ? true : false );
return apply_filters( 'is_sportspress', ( is_singular( sp_post_types() ) ) ? true : false );
}
/**