Taxonomy: Fix caching issues in WP_Term_Query class.

Introduced [52836] when passing `child_of` or `pad_counts` parameters to `get_terms` or `WP_Term_Query` class, the array of terms received by the query, was not correctly cached. This 
change simplifies the logic in `WP_Term_Query` and ensures terms are correctly cached. This change also, improves performance, by only caching an array of term ids where possible.  

Props denishua, spacedmonkey, oztaser, peterwilsoncc, SergeyBiryukov, georgestephanis, jnz31, knutsp, mukesh27, costdev.
Fixes #55837.



git-svn-id: https://develop.svn.wordpress.org/trunk@53496 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Jonny Harris
2022-06-14 11:41:33 +00:00
parent 2aa8e490e0
commit 6d89ea8f09
3 changed files with 125 additions and 44 deletions

View File

@@ -23,7 +23,7 @@ $wp_version = '6.1-alpha-53344-src';
*
* @global int $wp_db_version
*/
$wp_db_version = 51917;
$wp_db_version = 53496;
/**
* Holds the TinyMCE version.