Display username (user_login) rather than user_nicename in Toolbar. fixes #22121.
git-svn-id: http://core.svn.wordpress.org/trunk@23360 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
142f8bbe58
commit
42a3edc83d
|
@ -174,8 +174,8 @@ function wp_admin_bar_my_account_menu( $wp_admin_bar ) {
|
|||
$user_info = get_avatar( $user_id, 64 );
|
||||
$user_info .= "<span class='display-name'>{$current_user->display_name}</span>";
|
||||
|
||||
if ( $current_user->display_name !== $current_user->user_nicename )
|
||||
$user_info .= "<span class='username'>{$current_user->user_nicename}</span>";
|
||||
if ( $current_user->display_name !== $current_user->user_login )
|
||||
$user_info .= "<span class='username'>{$current_user->user_login}</span>";
|
||||
|
||||
$wp_admin_bar->add_menu( array(
|
||||
'parent' => 'user-actions',
|
||||
|
|
Loading…
Reference in New Issue