[wp-trac] [WordPress Trac] #58685: Fix return description for wp_count_posts()

WordPress Trac noreply at wordpress.org
Sat Jul 1 10:02:19 UTC 2023


#58685: Fix return description for wp_count_posts()
-------------------------------+-----------------------------
 Reporter:  crstauf            |       Owner:  SergeyBiryukov
     Type:  defect (bug)       |      Status:  closed
 Priority:  normal             |   Milestone:  6.3
Component:  Posts, Post Types  |     Version:
 Severity:  normal             |  Resolution:  fixed
 Keywords:  has-patch          |     Focuses:  docs
-------------------------------+-----------------------------
Changes (by SergeyBiryukov):

 * owner:  (none) => SergeyBiryukov
 * status:  new => closed
 * resolution:   => fixed


Comment:

 In [changeset:"56120" 56120]:
 {{{
 #!CommitTicketReference repository="" revision="56120"
 Docs: Correct `@return` description for `wp_count_posts()`.

 Add a note that `wp_count_posts()` returns an empty object if the post
 type passed to the function does not exist.

 Follow-up to [6730], [6808], [8081], [24826], [29093], [51885].

 Props crstauf, Ov3rfly.
 Fixes #58685.
 }}}

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


More information about the wp-trac mailing list