Menus: Allow empty taxonomy terms to be surfaced when searching for items.
This brings the behaviour inline with that of browsing terms or using the All Items tab, which correctly shows empty terms. Props birgire, audrasjb Fixes #45298 Built from https://develop.svn.wordpress.org/trunk@47747 git-svn-id: http://core.svn.wordpress.org/trunk@47523 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
cc4e27142e
commit
1a27d51b48
|
@ -113,6 +113,7 @@ function _wp_ajax_menu_quick_search( $request = array() ) {
|
||||||
'taxonomy' => $matches[2],
|
'taxonomy' => $matches[2],
|
||||||
'name__like' => $query,
|
'name__like' => $query,
|
||||||
'number' => 10,
|
'number' => 10,
|
||||||
|
'hide_empty' => false,
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
if ( empty( $terms ) || is_wp_error( $terms ) ) {
|
if ( empty( $terms ) || is_wp_error( $terms ) ) {
|
||||||
|
|
|
@ -369,6 +369,7 @@ final class WP_Customize_Nav_Menus {
|
||||||
'taxonomies' => $taxonomies,
|
'taxonomies' => $taxonomies,
|
||||||
'name__like' => $args['s'],
|
'name__like' => $args['s'],
|
||||||
'number' => 20,
|
'number' => 20,
|
||||||
|
'hide_empty' => false,
|
||||||
'offset' => 20 * ( $args['pagenum'] - 1 ),
|
'offset' => 20 * ( $args['pagenum'] - 1 ),
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
|
|
|
@ -13,7 +13,7 @@
|
||||||
*
|
*
|
||||||
* @global string $wp_version
|
* @global string $wp_version
|
||||||
*/
|
*/
|
||||||
$wp_version = '5.5-alpha-47746';
|
$wp_version = '5.5-alpha-47747';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||||
|
|
Loading…
Reference in New Issue