[wp-trac] [WordPress Trac] #16985: XML-RPC endpoint set the datetime when saving a Draft

WordPress Trac noreply at wordpress.org
Sat Sep 26 03:37:55 UTC 2015


#16985: XML-RPC endpoint set the datetime when saving a Draft
----------------------------------------+-----------------------------
 Reporter:  daniloercoli                |       Owner:  wonderboymusic
     Type:  defect (bug)                |      Status:  closed
 Priority:  normal                      |   Milestone:  4.4
Component:  XML-RPC                     |     Version:  3.1
 Severity:  normal                      |  Resolution:  fixed
 Keywords:  has-patch needs-unit-tests  |     Focuses:
----------------------------------------+-----------------------------
Changes (by wonderboymusic):

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


Comment:

 In [changeset:"34572"]:
 {{{
 #!CommitTicketReference repository="" revision="34572"
 XML-RPC: In `wp_xmlrpc_server::mw_newPost()`, if `$dateCreated` is not
 set, don't set `post_date` and `post_date_gmt`. It calls
 `wp_insert_post()`, which will handle it correctly. The problem was drafts
 being created and GMT date being set. It shouldn't be.

 Adds unit test.

 Fixes #16985.
 }}}

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


More information about the wp-trac mailing list