summaryrefslogtreecommitdiffstats
path: root/lib/private/L10N/Factory.php
diff options
context:
space:
mode:
authorRoeland Jago Douma <rullzer@users.noreply.github.com>2018-05-23 23:45:24 +0200
committerGitHub <noreply@github.com>2018-05-23 23:45:24 +0200
commit84482eb25a16dd381908efa7c064eb5f3fbfe0b5 (patch)
treefdf15e913dc297332bf3b1d3236182d69358434b /lib/private/L10N/Factory.php
parent6b6d522969c6f7613c8f897517d172de3d9646a4 (diff)
parent4286e17777433caac06859c744ff3f3fbbf95e8b (diff)
downloadnextcloud-server-84482eb25a16dd381908efa7c064eb5f3fbfe0b5.tar.gz
nextcloud-server-84482eb25a16dd381908efa7c064eb5f3fbfe0b5.zip
Merge pull request #9435 from nextcloud/bugfix/noid/fix_force_language_html_attr
make sure force language is reflected in html lang attribute
Diffstat (limited to 'lib/private/L10N/Factory.php')
-rw-r--r--lib/private/L10N/Factory.php5
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/private/L10N/Factory.php b/lib/private/L10N/Factory.php
index 759340a63c3..e8a734f412c 100644
--- a/lib/private/L10N/Factory.php
+++ b/lib/private/L10N/Factory.php
@@ -131,6 +131,11 @@ class Factory implements IFactory {
* @return string language If nothing works it returns 'en'
*/
public function findLanguage($app = null) {
+ $forceLang = $this->config->getSystemValue('force_language', false);
+ if (is_string($forceLang)) {
+ $this->requestLanguage = $forceLang;
+ }
+
if ($this->requestLanguage !== '' && $this->languageExists($app, $this->requestLanguage)) {
return $this->requestLanguage;
}