Don't assume queried object is a term. Fixes non-existent var notice. Props filosofo. fixes #15944
git-svn-id: http://svn.automattic.com/wordpress/trunk@17109 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
1fe263e46c
commit
09f625b796
wp-includes
|
@ -426,7 +426,10 @@ function _wp_menu_item_classes_by_context( &$menu_items ) {
|
|||
'taxonomy' == $parent_item->type &&
|
||||
isset( $possible_taxonomy_ancestors[ $parent_item->object ] ) &&
|
||||
in_array( $parent_item->object_id, $possible_taxonomy_ancestors[ $parent_item->object ] ) &&
|
||||
$parent_item->object_id != $queried_object->term_id
|
||||
(
|
||||
! isset( $queried_object->term_id ) ||
|
||||
$parent_item->object_id != $queried_object->term_id
|
||||
)
|
||||
)
|
||||
)
|
||||
) {
|
||||
|
|
Loading…
Reference in New Issue