Commit 90673b9066 for wordpress.org
commit 90673b90661716349429bec42759d545d5651b4d
Author: Felix Arntz <felix-arntz@leaves-and-love.net>
Date: Tue Sep 17 17:00:14 2024 +0000
Taxonomy: Remove redundant `$taxonomies` value from cache keys used for `WP_Term_Query`.
Props niravsherasiya7707, spacedmonkey.
Fixes #59594.
See #35381.
Built from https://develop.svn.wordpress.org/trunk@59028
git-svn-id: http://core.svn.wordpress.org/trunk@58424 1a063a9b-81f0-0310-95a4-ce76da25c4cd
diff --git a/wp-includes/class-wp-term-query.php b/wp-includes/class-wp-term-query.php
index 25baaa8dd1..77a3b9d23f 100644
--- a/wp-includes/class-wp-term-query.php
+++ b/wp-includes/class-wp-term-query.php
@@ -1170,12 +1170,11 @@ class WP_Term_Query {
if ( 'count' !== $args['fields'] && 'all_with_object_id' !== $args['fields'] ) {
$cache_args['fields'] = 'all';
}
- $taxonomies = (array) $args['taxonomy'];
// Replace wpdb placeholder in the SQL statement used by the cache key.
$sql = $wpdb->remove_placeholder_escape( $sql );
- $key = md5( serialize( $cache_args ) . serialize( $taxonomies ) . $sql );
+ $key = md5( serialize( $cache_args ) . $sql );
$last_changed = wp_cache_get_last_changed( 'terms' );
return "get_terms:$key:$last_changed";
}
diff --git a/wp-includes/version.php b/wp-includes/version.php
index 5494204799..5e802961e7 100644
--- a/wp-includes/version.php
+++ b/wp-includes/version.php
@@ -16,7 +16,7 @@
*
* @global string $wp_version
*/
-$wp_version = '6.7-alpha-59027';
+$wp_version = '6.7-alpha-59028';
/**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.