From 83e1634d5ee20a5cb38a55dbf45cf843b32a59e3 Mon Sep 17 00:00:00 2001 From: "Dominik Schilling (ocean90)" Date: Fri, 19 May 2017 14:35:03 +0000 Subject: [PATCH] Dashboard: Use `get_user_locale()` for the news feed cache key. Since the feed URL can be localized the cache key has to be built with the same locale as the current user is using. Props iandunn. Fixes #40417. git-svn-id: https://develop.svn.wordpress.org/trunk@40793 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-admin/includes/dashboard.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/wp-admin/includes/dashboard.php b/src/wp-admin/includes/dashboard.php index 124dea2206..af61be3fc1 100644 --- a/src/wp-admin/includes/dashboard.php +++ b/src/wp-admin/includes/dashboard.php @@ -980,7 +980,7 @@ function wp_dashboard_cached_rss_widget( $widget_id, $callback, $check_urls = ar $check_urls = array( $widgets[$widget_id]['url'] ); } - $locale = get_locale(); + $locale = get_user_locale(); $cache_key = 'dash_' . md5( $widget_id . '_' . $locale ); if ( false !== ( $output = get_transient( $cache_key ) ) ) { echo $output;