[wp-trac] [WordPress Trac] #48772: Missing post ID as parameter for get_comments_number_text()

WordPress Trac noreply at wordpress.org
Tue Feb 25 17:14:10 UTC 2020


#48772: Missing post ID as parameter for get_comments_number_text()
------------------------------+-----------------------
 Reporter:  Hinjiriyo         |       Owner:  donmhico
     Type:  enhancement       |      Status:  reopened
 Priority:  normal            |   Milestone:  5.4
Component:  Comments          |     Version:  4.0
 Severity:  normal            |  Resolution:
 Keywords:  has-patch commit  |     Focuses:
------------------------------+-----------------------

Comment (by SergeyBiryukov):

 Replying to [comment:21 peterwilsoncc]:
 > Is it worth switching to an arguments array? Four parameters is workable
 but approaching an unwieldy number, switching to an array could be handy
 going forward.

 Thanks for bringing this up, I think that's a good option to consider if
 the function ever gets more than five arguments. For now, I would just
 like to make function signatures for `comments_number()` and
 `get_comments_number_text()` consistent:
 {{{
 function comments_number( $zero = false, $one = false, $more = false,
 $post_id = 0 )
 function get_comments_number_text( $zero = false, $one = false, $more =
 false, $post_id = 0 )
 }}}

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


More information about the wp-trac mailing list