protected function choosePrioritizedLanguageCode(array $entries, $showAllTranslations, array $prioritizedLanguageList)
    {
        foreach ($prioritizedLanguageList as $prioritizedLanguageCode) {
            if (isset($entries['translations'][$prioritizedLanguageCode])) {
                return $prioritizedLanguageCode;
            }
        }

        if ($entries['always-available'] || $showAllTranslations) {
            reset($entries['translations']);

            return key($entries['translations']);
        }

        return false;
    }