ajax devise authentication flow