Skip to content

Commit

Permalink
fix: corrected language handling in Application class
Browse files Browse the repository at this point in the history
  • Loading branch information
thorsten committed Jan 7, 2025
1 parent 4dafa58 commit c2409b5
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion phpmyfaq/src/phpMyFAQ/Application.php
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,10 @@ private function setLanguage(): string
if (!is_null($this->container)) {
$configuration = $this->container->get('phpmyfaq.configuration');
$language = $this->container->get('phpmyfaq.language');
$currentLanguage = $language->setLanguageByAcceptLanguage();
$currentLanguage = $language->setLanguage(
$configuration->get('main.languageDetection'),
$configuration->get('main.language')
);

require sprintf('%s/language_en.php', PMF_TRANSLATION_DIR);
if (Language::isASupportedLanguage($currentLanguage)) {
Expand Down

0 comments on commit c2409b5

Please sign in to comment.