Don't close the response Body if it's nil

When an http error is returned, the response body may be nil.  Don't try to close it in that case.