isUserAuthenticated fix