use response.status to check whether the user is connected