[wp-trac] [WordPress Trac] #32762: Comment meta queries cannot be set in WP_Comment_Query via pre_get_comments

WordPress Trac noreply at wordpress.org
Wed Jun 24 13:05:37 UTC 2015


#32762: Comment meta queries cannot be set in WP_Comment_Query via pre_get_comments
--------------------------+---------------------------
 Reporter:  needle        |       Owner:  boonebgorges
     Type:  defect (bug)  |      Status:  closed
 Priority:  normal        |   Milestone:  4.3
Component:  Comments      |     Version:  4.2
 Severity:  normal        |  Resolution:  fixed
 Keywords:  has-patch     |     Focuses:
--------------------------+---------------------------

Comment (by side777):

 > That means that modifying `$query->query_vars['meta_key']` should have
 had no effect.

 That's why you had to call `meta_query->parse_query_vars()` again after
 altering the meta query. Developers are aware of that. (See the example)

 It seems that we now have introduced a third call... but I'm glad it's
 fixed!

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


More information about the wp-trac mailing list