From 59cb3c0dddb8499f39da72f950ffcbd3f831e2d5 Mon Sep 17 00:00:00 2001 From: westi Date: Mon, 26 Sep 2011 08:40:31 +0000 Subject: [PATCH] Only show 'About this version' menu item to logged in users. git-svn-id: http://svn.automattic.com/wordpress/trunk@18777 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-includes/admin-bar.php | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/wp-includes/admin-bar.php b/wp-includes/admin-bar.php index 015b4b9cc..8f1559cd3 100644 --- a/wp-includes/admin-bar.php +++ b/wp-includes/admin-bar.php @@ -81,13 +81,15 @@ function wp_admin_bar_wp_menu( $wp_admin_bar ) { ), ) ); - // Add "About This Version" link - $wp_admin_bar->add_menu( array( - 'parent' => 'wp-logo', - 'id' => 'about', - 'title' => __('About This Version'), - 'href' => admin_url('about.php'), - ) ); + if ( is_user_logged_in() ) { + // Add "About This Version" link + $wp_admin_bar->add_menu( array( + 'parent' => 'wp-logo', + 'id' => 'about', + 'title' => __('About This Version'), + 'href' => admin_url('about.php'), + ) ); + } // Add codex link $wp_admin_bar->add_menu( array( @@ -692,4 +694,4 @@ function _get_admin_bar_pref( $context = 'front', $user = 0 ) { return 'true' === $pref; } -?> \ No newline at end of file +?>