[wp-trac] [WordPress Trac] #38494: WP REST API: Stale Post Status on DELETE of Post

WordPress Trac noreply at wordpress.org
Thu Nov 3 20:05:01 UTC 2016


#38494: WP REST API: Stale Post Status on DELETE of Post
--------------------------------------+---------------------
 Reporter:  timmydcrawford            |       Owner:  rmccue
     Type:  enhancement               |      Status:  closed
 Priority:  normal                    |   Milestone:  4.7
Component:  REST API                  |     Version:  trunk
 Severity:  normal                    |  Resolution:  fixed
 Keywords:  has-unit-tests has-patch  |     Focuses:
--------------------------------------+---------------------
Changes (by rachelbaker):

 * status:  assigned => closed
 * resolution:   => fixed


Comment:

 In [changeset:"39126"]:
 {{{
 #!CommitTicketReference repository="" revision="39126"
 REST API: Modify the structure of our DELETE responses to be more
 explicit.

 Add the `deleted` property to the root of the Response object to
 communicate if the delete action was successful. Move the state of the
 resource prior to the delete request under a new `previous` property.  As
 a result DELETE responses are now structured like so:
  `{ deleted: true, previous: { ... } }`

 Also includes helpful information to DELETE requests for resources that
 are not trashable.

 Props timmydcrawford, rmccue, jnylen0.
 Fixes #38494.
 }}}

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


More information about the wp-trac mailing list