Skip to content

Commit

Permalink
Start object cache if needed
Browse files Browse the repository at this point in the history
  • Loading branch information
swissspidy committed Jun 18, 2024
1 parent 00bd7aa commit 07c164c
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/wp-includes/l10n.php
Original file line number Diff line number Diff line change
Expand Up @@ -2050,6 +2050,7 @@ static function ( $a, $b ) use ( $codes, $prios ) {
* Only works if either the object cache or the database are already available.
*/
if ( wp_using_ext_object_cache() || wp_installing() ) {
wp_start_object_cache();
$translations = wp_cache_get( 'available_translations', 'site-transient' );
} elseif ( isset( $wpdb ) ) {
$translations = get_site_option( '_site_transient_available_translations' );
Expand Down

0 comments on commit 07c164c

Please sign in to comment.