[wp-trac] [WordPress Trac] #36462: Updating or publishing a (custom) post that hasn't loaded completely closes comments

WordPress Trac noreply at wordpress.org
Mon May 23 23:05:07 UTC 2016


#36462: Updating or publishing a (custom) post that hasn't loaded completely closes
comments
-------------------------------+-----------------------------
 Reporter:  SeBsZ              |       Owner:
     Type:  defect (bug)       |      Status:  new
 Priority:  normal             |   Milestone:  Future Release
Component:  Posts, Post Types  |     Version:  4.4.2
 Severity:  normal             |  Resolution:
 Keywords:  needs-patch        |     Focuses:  administration
-------------------------------+-----------------------------

Comment (by SeBsZ):

 I just created a simple patch, which I've tested and can confirm works.

 I've added two hidden fields in meta-boxes.php, one for comment_status and
 the other for ping_status. Then I removed the code in post.php where it
 closes the comments and ping_status if the POST data is missing.

 I checked and by default, if the POST data is missing both fields are set
 to what they currently are, so nothing is changed in that case. Then if
 the POST data does exist, then it'll set the accordingly. This is exactly
 what we want.

 Of course this is just for these two checkboxes, this should probably be
 expanded to work for other checkboxes so I'm not sure how to go about that
 here.

 Let me know if I can be of further help to get this implemented.

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


More information about the wp-trac mailing list