Ensure response.error is populated correctly.

Thanks @dpnova.