[wp-trac] [WordPress Trac] #35402: per_page parameter no longer works in wp_list_comments

WordPress Trac noreply at wordpress.org
Wed Jan 20 07:58:25 UTC 2016


#35402: per_page parameter no longer works in wp_list_comments
--------------------------+---------------------------
 Reporter:  Ninos Ego     |       Owner:  boonebgorges
     Type:  defect (bug)  |      Status:  closed
 Priority:  normal        |   Milestone:  4.4.2
Component:  Comments      |     Version:  4.4.1
 Severity:  major         |  Resolution:  fixed
 Keywords:  fixed-major   |     Focuses:  template
--------------------------+---------------------------
Changes (by dd32):

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


Comment:

 In [changeset:"36360"]:
 {{{
 #!CommitTicketReference repository="" revision="36360"
 Comments: Respect custom pagination params when using `wp_list_comments()`
 in a query loop.

 [36157] fixed a problem, introduced in 4.4, that caused custom pagination
 parameters passed to `wp_list_comments()`. However, the fix introduced in
 that
 changeset was limited to the `is_singular()` context, so that the bug
 remained
 when `wp_list_comments()` is used within a non-singular `WP_Query` loop.
 We
 fix this by removing the `is_singular()` check and using the more general
 `get_the_ID()` to identify the correct post_id to use for the secondary
 comment query.

 Merges [36324] to the 4.4 branch.
 Props boonebgorges.
 Fixes #35402.
 }}}

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


More information about the wp-trac mailing list