Add function to check if post type is config type
This commit is contained in:
@@ -67,7 +67,7 @@ class SP_Admin_Menus {
|
||||
*/
|
||||
public function menu_highlight() {
|
||||
global $typenow, $submenu;
|
||||
if ( in_array( $typenow, array( 'sp_result', 'sp_outcome', 'sp_column', 'sp_performance', 'sp_metric' ) ) )
|
||||
if ( sp_is_config_type( $typenow ) )
|
||||
$this->highlight_admin_menu( 'sportspress', null );
|
||||
elseif ( $typenow == 'sp_calendar' )
|
||||
$this->highlight_admin_menu( 'edit.php?post_type=sp_event', 'edit.php?post_type=sp_calendar' );
|
||||
|
||||
Reference in New Issue
Block a user