fixed Logout bug