[wp-trac] [WordPress Trac] #41370: REST API: Attempting to create an existing term yields HTTP 500

WordPress Trac noreply at wordpress.org
Sun Dec 3 19:08:25 UTC 2017


#41370: REST API: Attempting to create an existing term yields HTTP 500
-------------------------------------------------+-------------------------
 Reporter:  jnylen0                              |       Owner:  kadamwhite
     Type:  defect (bug)                         |      Status:  closed
 Priority:  normal                               |   Milestone:  4.9
Component:  REST API                             |     Version:  4.7
 Severity:  normal                               |  Resolution:  fixed
 Keywords:  good-first-bug has-unit-tests has-   |     Focuses:  rest-api
  patch commit                                   |
-------------------------------------------------+-------------------------

Comment (by rachelbaker):

 In [changeset:"42354"]:
 {{{
 #!CommitTicketReference repository="" revision="42354"
 REST API: Correct HTTP status code in error for requests to create a
 duplicate term.

 The 409 error code is intended for situations where it is expected that
 the user will resolve the conflict and resubmit the same request. We use
 400 error codes for other routes when a duplicate request is made. The 400
 status code tells the user they need to modify their request for it to be
 successful.

 Props shooper.
 Fixes #42781. See #41370.
 }}}

--
Ticket URL: <https://core.trac.wordpress.org/ticket/41370#comment:17>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list