From 430afafeb7eec1e1d39b6f588ddcfe16ce89b6a2 Mon Sep 17 00:00:00 2001 From: Reedy Date: Sun, 6 Mar 2022 14:41:10 +0000 Subject: [PATCH] Use ExtensionRegistry to see if Babel is loaded Change-Id: Iabc24b4580bab39a6d232d61e9c52a641cce41a3 --- includes/Hooks.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/Hooks.php b/includes/Hooks.php index da9a58bc..f5dc2eb3 100644 --- a/includes/Hooks.php +++ b/includes/Hooks.php @@ -422,7 +422,7 @@ class Hooks implements $vars['wgULSAcceptLanguageList'] = array_keys( $out->getRequest()->getAcceptLang() ); } - if ( $loggedIn && class_exists( Babel::class ) ) { + if ( $loggedIn && ExtensionRegistry::getInstance()->isLoaded( 'Babel' ) ) { $userLanguageInfo = Babel::getCachedUserLanguageInfo( $user ); // This relies on the fact that Babel levels are 'N' and