Remove redundant code
This commit is contained in:
@@ -422,17 +422,6 @@ class SP_Calendar extends SP_Secondary_Post {
|
|||||||
else:
|
else:
|
||||||
$events = null;
|
$events = null;
|
||||||
endif;
|
endif;
|
||||||
|
|
||||||
// Filter out unessecary events if we are showing past meetings
|
|
||||||
if ( $this->teams_past ){
|
|
||||||
$events_past = array();
|
|
||||||
foreach ( $events as $single_event ) {
|
|
||||||
if ( sort( get_post_meta( $single_event->ID, 'sp_team' ) ) === sort( $this->teams_past ) ) {
|
|
||||||
$events_past[] = $single_event;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
$events = $events_past;
|
|
||||||
}
|
|
||||||
|
|
||||||
// Remove any calendar selection filters
|
// Remove any calendar selection filters
|
||||||
remove_filter( 'posts_where', array( $this, 'range' ) );
|
remove_filter( 'posts_where', array( $this, 'range' ) );
|
||||||
|
|||||||
Reference in New Issue
Block a user