[wp-trac] [WordPress Trac] #61738: admin_bar_menu node my-account returns null
WordPress Trac
noreply at wordpress.org
Wed Jul 24 06:54:07 UTC 2024
#61738: admin_bar_menu node my-account returns null
----------------------------+-----------------------------
Reporter: michaelwp85 | Owner: (none)
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Administration | Version: 6.6.1
Severity: normal | Keywords:
Focuses: |
----------------------------+-----------------------------
Getting admin bar node "my-account" returns null after updating to 6.6.1
{{{#!php
<?php
add_action('admin_bar_menu', function (WP_Admin_Bar $adminBar):
WP_Admin_Bar {
var_dump($adminBar->get_node('my-account'));
}
}}}
**6.6.0:**
{{{
$adminBar->get_node('my-account'))
}}}
{{{
{#3866 ▼
+"id": "my-account"
+"title": "Howdy, <span class="display-name">__ACCOUNT__</span><img
alt=''
src='https://secure.gravatar.com/avatar/....?s=26&d=mm&r=g' ▶"
+"parent": "top-secondary"
+"href": "https://core.test/wp/wp-admin/profile.php"
+"group": false
+"meta": array:3 [▶]
}
}}}
{{{
$adminBar
}}}
{{{
WP_Admin_Bar {#3349 ▼
-nodes: array:4 [▼
"user-actions" => {#3362 ▶}
"user-info" => {#3546 ▶}
"logout" => {#3545 ▶}
"my-account" => {#3893 ▶}
]
-bound: false
+user: {#3348 ▶}
+menu: []
}
}}}
**6.6.1:**
{{{
$adminBar->get_node('my-account'))
}}}
{{{
null
}}}
{{{
$adminBar
}}}
{{{
WP_Admin_Bar {#3352 ▼
-nodes: array:3 [▼
"user-actions" => {#3365 ▶}
"user-info" => {#3549 ▶}
"logout" => {#3548 ▶}
]
-bound: false
+user: {#3351 ▶}
+menu: []
}
}}}
--
Ticket URL: <https://core.trac.wordpress.org/ticket/61738>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list