[wp-trac] [WordPress Trac] #42691: WP_Term_Query get_terms generates invalid sql queries

WordPress Trac noreply at wordpress.org
Tue Dec 5 03:28:10 UTC 2017


#42691: WP_Term_Query get_terms generates invalid sql queries
--------------------------+------------------
 Reporter:  GM_Alex       |       Owner:
     Type:  defect (bug)  |      Status:  new
 Priority:  normal        |   Milestone:  5.0
Component:  Taxonomy      |     Version:  4.9
 Severity:  normal        |  Resolution:
 Keywords:  has-patch     |     Focuses:
--------------------------+------------------
Changes (by boonebgorges):

 * keywords:   => has-patch
 * component:  General => Taxonomy
 * milestone:  Awaiting Review => 5.0


Comment:

 Thanks very much for verifying, @GM_Alex. [attachment:42691.2.diff] brings
 your original patch a bit closer in line with naming conventions for WP,
 and also adds some tests. Can you give it another look please?

 (For the record, while it's perhaps true that the bad SQL in
 `transform_query()` dates from 4.9, the `get_term()` mapping has happened
 for a lot longer, so this bug could have - and probably did - arise in
 other contexts before 4.9.)

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


More information about the wp-trac mailing list