From 01d8979bee0ac79283a1fd96b8bd710fd874f1cb Mon Sep 17 00:00:00 2001 From: Andrew Ozz Date: Tue, 17 Jul 2018 14:38:24 +0000 Subject: [PATCH] Customize: Do not attempt to count uncountable value. Props dlh. Fixes #44104. Built from https://develop.svn.wordpress.org/trunk@43480 git-svn-id: http://core.svn.wordpress.org/trunk@43307 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-includes/class-wp-customize-nav-menus.php | 2 +- wp-includes/version.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/wp-includes/class-wp-customize-nav-menus.php b/wp-includes/class-wp-customize-nav-menus.php index 1a55fa6ce2..d2a346d5b0 100644 --- a/wp-includes/class-wp-customize-nav-menus.php +++ b/wp-includes/class-wp-customize-nav-menus.php @@ -324,7 +324,7 @@ final class WP_Customize_Nav_Menus { // Prepend list of posts with nav_menus_created_posts search results on first page. $nav_menus_created_posts_setting = $this->manager->get_setting( 'nav_menus_created_posts' ); - if ( 1 === $args['pagenum'] && $nav_menus_created_posts_setting && count( $nav_menus_created_posts_setting ) > 0 ) { + if ( 1 === $args['pagenum'] && $nav_menus_created_posts_setting && count( $nav_menus_created_posts_setting->value() ) > 0 ) { $stub_post_query = new WP_Query( array_merge( $query, diff --git a/wp-includes/version.php b/wp-includes/version.php index a8e6f35702..98f43f06df 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -4,7 +4,7 @@ * * @global string $wp_version */ -$wp_version = '5.0-alpha-43478'; +$wp_version = '5.0-alpha-43480'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.