From 005fe51131a75ff8feff8befaa6901ceae4a72e3 Mon Sep 17 00:00:00 2001 From: Scott Taylor Date: Fri, 15 Nov 2013 02:37:10 +0000 Subject: [PATCH] Don't call is_home() before the query is run in Featured Content's pre_get_posts hook callback. Built from https://develop.svn.wordpress.org/trunk@26189 git-svn-id: http://core.svn.wordpress.org/trunk@26097 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-content/themes/twentyfourteen/inc/featured-content.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/wp-content/themes/twentyfourteen/inc/featured-content.php b/wp-content/themes/twentyfourteen/inc/featured-content.php index 8934de34cd..348abd4b45 100644 --- a/wp-content/themes/twentyfourteen/inc/featured-content.php +++ b/wp-content/themes/twentyfourteen/inc/featured-content.php @@ -195,7 +195,7 @@ class Featured_Content { public static function pre_get_posts( $query = false ) { // Bail if not home, not a query, not main query. - if ( ! is_home() || ! is_a( $query, 'WP_Query' ) || ! $query->is_main_query() ) + if ( ! is_a( $query, 'WP_Query' ) || ! $query->is_main_query() || ! is_home() ) return; $page_on_front = get_option( 'page_on_front' );