Called when an http request completes.
If a network error occured, the request status will be -1.
Otherwise, the request status will contain the status code returned by the server.