wordpress-develop/src/wp-includes/rest-api
Joe Hoyle a375d93001 REST API: Improve formatting of failed validation errors.
If a validation_callback returns a WP_Error it should give the same response format as if it returned `false`. This makes programmatically reading the validation errors better.

Props bradyvercher for initial patch.
Fixes #35028.


git-svn-id: https://develop.svn.wordpress.org/trunk@35890 602fd350-edb4-49c9-b593-d223f7449a82
2015-12-12 18:22:02 +00:00
..
class-wp-rest-request.php REST API: Improve formatting of failed validation errors. 2015-12-12 18:22:02 +00:00
class-wp-rest-response.php Update WP_REST_Response::as_error() to handle the new format error responses introduced in [35653]. 2015-11-18 18:28:55 +00:00
class-wp-rest-server.php REST API: Core typically sends nocache headers on all auth'ed responses, as in wp, admin-ajax, etc. Because the REST API infrastructure is hooked in pre-wp, we should be setting this ourselves. 2015-12-04 23:35:54 +00:00