[wp-trac] [WordPress Trac] #30854: `wp_insert_post` doesn't save revision for new published post

WordPress Trac noreply at wordpress.org
Thu Feb 4 19:43:42 UTC 2021


#30854: `wp_insert_post` doesn't save revision for new published post
--------------------------+------------------------------
 Reporter:  JamesDiGioia  |       Owner:  adamsilverstein
     Type:  defect (bug)  |      Status:  assigned
 Priority:  normal        |   Milestone:  5.7
Component:  Revisions     |     Version:
 Severity:  normal        |  Resolution:
 Keywords:  needs-patch   |     Focuses:
--------------------------+------------------------------

Comment (by hellofromTonya):

 Replying to [comment:10 adamsilverstein]:
 > In [attachment:30854.diff]:
 >
 > * Hook `wp_save_post_revision` on to `new_to_publish` in addition to
 `update_post` - triggering a revision save when a new post is created
 > * Adjust revisions unit test to accommodate change: bump expected
 revision counts by 1, add first revision to order by comparisons
 >
 > This needs more testing, especially around creating posts in the admin
 interface and verifying that we aren't getting duplicate initial
 revisions.

 Hey @adamsilverstein, Can you provide a testing strategy please to give
 guidance for manual testers to do the testing and provide needed feedback?

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


More information about the wp-trac mailing list