Note: This should only be used in WP_REST_Server::serve_request(), as it
cannot handle WP_Error internally. All callbacks and other internal methods
should instead return a WP_Error with the data set to an array that includes
a 'status' key, with the value being the HTTP status to send.