diff --git a/includes/ForeignNotifications.php b/includes/ForeignNotifications.php index 92a09457d..c3456a3f1 100644 --- a/includes/ForeignNotifications.php +++ b/includes/ForeignNotifications.php @@ -243,7 +243,7 @@ class EchoForeignNotifications { // try to fetch site name for this specific wiki, or fallback to the // general project's sitename if there is no override $wikiName = $wgConf->get( 'wgSitename', $wikiId ) ?: $wgConf->get( 'wgSitename', $site ); - $langName = Language::fetchLanguageName( $langCode, $wgLang->getCode() ); + $langName = Language::fetchLanguageName( $langCode ?? '', $wgLang->getCode() ); if ( !$langName ) { // if we can't find a language name (in language-agnostic