fix login/logout setup