Implement through "additional" termbox request during EntityViewPlaceholderExpander
Request is needed if user's configuration (currently "preferred languages" only) differs from the configuration that is used to build the generic termbox version that is stored in ParserCache.
Idea for getting to the language fallback chains to compare:
$wikibaseRepo = WikibaseRepo::getDefaultInstance(); $parserCacheLanguages = $wikibaseRepo->getLanguageFallbackChainFactory() ->newFromLanguage( $language ); $userPreferredLanguages = $wikibaseRepo->getLanguageFallbackChainFactory() ->newFromContext( RequestContext::getMain() );