Skip to content

Commit

Permalink
Merge pull request #9 from boonebgorges/no-logout-button-for-anon-users
Browse files Browse the repository at this point in the history
Don't add Log Out link for non-logged-in users.
  • Loading branch information
joedolson committed Jun 13, 2016
2 parents 2db10f4 + f6471bb commit 4c13f3f
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions wp-accessibility.php
Expand Up @@ -395,6 +395,10 @@ function wpa_jquery_asl() {
// http://www.coolfields.co.uk/2013/02/wordpress-permanently-visible-log-out-link-plugin-version-0-1/
add_action( 'admin_bar_menu', 'wpa_logout_item', 11 );
function wpa_logout_item( $admin_bar ) {
if ( ! is_user_logged_in() ) {
return;
}

$args = array(
'id' => 'wpa-logout',
'title' => 'Log Out',
Expand Down

0 comments on commit 4c13f3f

Please sign in to comment.