From cbadb65a2aa035a1781e03c370f6589a9ffaa1f5 Mon Sep 17 00:00:00 2001 From: audrasjb Date: Fri, 3 Dec 2021 11:36:09 +0000 Subject: [PATCH] REST API: Use global transients for URL details endpoint. Follow-up to [51973]. Props peterwilsoncc, costdev. Fixes #54499. Built from https://develop.svn.wordpress.org/trunk@52311 git-svn-id: http://core.svn.wordpress.org/trunk@51903 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- .../endpoints/class-wp-rest-url-details-controller.php | 4 ++-- wp-includes/version.php | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/wp-includes/rest-api/endpoints/class-wp-rest-url-details-controller.php b/wp-includes/rest-api/endpoints/class-wp-rest-url-details-controller.php index 27d8a9c6bf..3a0e3c797c 100644 --- a/wp-includes/rest-api/endpoints/class-wp-rest-url-details-controller.php +++ b/wp-includes/rest-api/endpoints/class-wp-rest-url-details-controller.php @@ -451,7 +451,7 @@ class WP_REST_URL_Details_Controller extends WP_REST_Controller { * @return mixed The value from the cache. */ private function get_cache( $key ) { - return get_transient( $key ); + return get_site_transient( $key ); } /** @@ -478,7 +478,7 @@ class WP_REST_URL_Details_Controller extends WP_REST_Controller { */ $cache_expiration = apply_filters( 'rest_url_details_cache_expiration', $ttl ); - return set_transient( $key, $data, $cache_expiration ); + return set_site_transient( $key, $data, $cache_expiration ); } /** diff --git a/wp-includes/version.php b/wp-includes/version.php index 483e09c9d8..a95b9b8511 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -16,7 +16,7 @@ * * @global string $wp_version */ -$wp_version = '5.9-beta1-52310'; +$wp_version = '5.9-beta1-52311'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.