Fixed the logout link appearing without logging in issue