WordPress/wp-includes/rest-api/endpoints
K. Adam White fe29c9c881 REST API: Return 409 status when attempting to create an existing term.
Fixes an issue where submitting a well-formed request to create a term inappropriately returns a 500 error status if that term already exists.
HTTP 5xx error codes should be reserved for unexpected server errors, so "409 Conflict" is a more appropriate response.

Props alibasheer, guzzilar, shooper.
Fixes #41370.


Built from https://develop.svn.wordpress.org/trunk@41737


git-svn-id: http://core.svn.wordpress.org/trunk@41571 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-10-04 16:24:46 +00:00
..
class-wp-rest-attachments-controller.php REST API: Support for objects in schema validation and sanitization. 2017-10-04 08:27:47 +00:00
class-wp-rest-comments-controller.php REST API: Avoid counting an uncountable type when checking read permissions for comment posts. 2017-10-04 15:38:49 +00:00
class-wp-rest-controller.php I18N: Add translator comments for placeholders in WP_REST_Controller strings. 2017-09-25 10:27:43 +00:00
class-wp-rest-post-statuses-controller.php REST API: Specify specific json-schema version. 2017-10-04 14:52:46 +00:00
class-wp-rest-post-types-controller.php REST API: Specify specific json-schema version. 2017-10-04 14:52:46 +00:00
class-wp-rest-posts-controller.php REST API: Specify specific json-schema version. 2017-10-04 14:52:46 +00:00
class-wp-rest-revisions-controller.php REST API: Specify specific json-schema version. 2017-10-04 14:52:46 +00:00
class-wp-rest-settings-controller.php REST API: Specify specific json-schema version. 2017-10-04 14:52:46 +00:00
class-wp-rest-taxonomies-controller.php REST API: Specify specific json-schema version. 2017-10-04 14:52:46 +00:00
class-wp-rest-terms-controller.php REST API: Return 409 status when attempting to create an existing term. 2017-10-04 16:24:46 +00:00
class-wp-rest-users-controller.php REST API: Specify specific json-schema version. 2017-10-04 14:52:46 +00:00