[wp-trac] [WordPress Trac] #43316: REST API: Support autosaves

WordPress Trac noreply at wordpress.org
Thu Nov 15 12:56:58 UTC 2018


#43316: REST API: Support autosaves
--------------------------------------+-----------------------
 Reporter:  kraftbj                   |       Owner:  rmccue
     Type:  enhancement               |      Status:  reopened
 Priority:  normal                    |   Milestone:  5.0
Component:  REST API                  |     Version:
 Severity:  normal                    |  Resolution:
 Keywords:  has-patch has-unit-tests  |     Focuses:  rest-api
--------------------------------------+-----------------------

Comment (by danielbachhuber):

 In [changeset:"43897" 43897]:
 {{{
 #!CommitTicketReference repository="" revision="43897"
 REST API: Avoid using 'parent' as path argument name for autosaves.

 When 'parent' is set as the path argument name, it gets passed down
 through to the `create_item()` method and can erroneously reset the
 'parent' value on the post itself. Instead, we rename the argument to 'id'
 and replicate the revision controller's `get_items_permissions_check()` to
 instead reference 'id'.

 Also ensures revision query params (of which there are many) aren't
 exposed as the query params for autosaves (of which there are two).

 Props TimothyBlynJacobs.
 See #43316.
 }}}

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


More information about the wp-trac mailing list