added logout link when user logged in with redirect