[wp-trac] [WordPress Trac] #29704: wp_ajax_replyto_comment does not define $comment_type before compact()

WordPress Trac noreply at wordpress.org
Tue Sep 23 03:28:52 UTC 2014


#29704: wp_ajax_replyto_comment does not define $comment_type before compact()
-------------------------------------------------+-------------------------
 Reporter:  nerrad                               |       Owner:
     Type:  defect (bug)                         |  wonderboymusic
 Priority:  normal                               |      Status:  closed
Component:  Comments                             |   Milestone:  4.1
 Severity:  normal                               |     Version:  4.0
 Keywords:  has-patch needs-testing needs-unit-  |  Resolution:  fixed
  tests                                          |     Focuses:
-------------------------------------------------+-------------------------
Changes (by wonderboymusic):

 * owner:   => wonderboymusic
 * status:  new => closed
 * resolution:   => fixed


Comment:

 In [changeset:"29758"]:
 {{{
 #!CommitTicketReference repository="" revision="29758"
 In `wp_ajax_replyto_comment()`, if `$_POST['comment_type']` is set, use it
 for the value of `$comment_type`, which the `compact()` call has assumed
 is set since [8720]. It never was.

 `wp_comment_reply()`'s output can be complete overridden by the
 `wp_comment_reply` filter, so this check is justified and makes the AJAX
 callback more flexible.

 Props nerrad.
 Fixes #29704.
 }}}

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


More information about the wp-trac mailing list