[wp-trac] [WordPress Trac] #35090: Query for comments where post isn't set

WordPress Trac noreply at wordpress.org
Fri Jan 22 20:19:51 UTC 2016


#35090: Query for comments where post isn't set
-----------------------------+---------------------------
 Reporter:  danielbachhuber  |       Owner:  boonebgorges
     Type:  defect (bug)     |      Status:  closed
 Priority:  normal           |   Milestone:  4.5
Component:  Comments         |     Version:
 Severity:  normal           |  Resolution:  fixed
 Keywords:                   |     Focuses:
-----------------------------+---------------------------
Changes (by boonebgorges):

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


Comment:

 In [changeset:"36381"]:
 {{{
 #!CommitTicketReference repository="" revision="36381"
 Allow comment query results to be limited to comments with comment_post_ID
 = 0.

 Previously, this was not possible due to an overly broad `empty()` check.

 Passing `null`, `false`, or `''` to 'post_id', or omitting 'post_id'
 altogether, will continue to return comments regardless of
 `comment_post_ID`,
 as before. Passing `0` or `'0'` will limit results to comments with no
 associated post.

 Props danielbachhuber.
 Fixes #35090.
 }}}

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


More information about the wp-trac mailing list