From dbceb01b83f80ec4e739cafd1924571751a1b308 Mon Sep 17 00:00:00 2001 From: Sergey Biryukov Date: Wed, 17 Jun 2020 19:45:56 +0000 Subject: [PATCH] Menus: Check the correct variable in `Walker_Nav_Menu_Edit::start_el()` when menu item is a taxonomy term. Follow-up to [45891]. Props ashour. Fixes #50415. git-svn-id: https://develop.svn.wordpress.org/trunk@48076 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-admin/includes/class-walker-nav-menu-edit.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/wp-admin/includes/class-walker-nav-menu-edit.php b/src/wp-admin/includes/class-walker-nav-menu-edit.php index fd5ea85219..39835e091c 100644 --- a/src/wp-admin/includes/class-walker-nav-menu-edit.php +++ b/src/wp-admin/includes/class-walker-nav-menu-edit.php @@ -74,7 +74,7 @@ class Walker_Nav_Menu_Edit extends Walker_Nav_Menu { if ( 'taxonomy' === $item->type ) { $original_object = get_term( (int) $item->object_id, $item->object ); - if ( $original_object && ! is_wp_error( $original_title ) ) { + if ( $original_object && ! is_wp_error( $original_object ) ) { $original_title = $original_object->name; } } elseif ( 'post_type' === $item->type ) {