fix login/logout refresh