Browse Source

fix use of findLocale

Signed-off-by: Georg Ehrke <developer@georgehrke.com>
Georg Ehrke 6 năm trước cách đây
mục cha
commit
b17d256761
2 tập tin đã thay đổi với 2 bổ sung2 xóa
  1. 1 1
      lib/private/L10N/Factory.php
  2. 1 1
      lib/private/TemplateLayout.php

+ 1 - 1
lib/private/L10N/Factory.php

@@ -126,7 +126,7 @@ class Factory implements IFactory {
 		}
 
 		if ($locale === null || !$this->localeExists($locale)) {
-			$locale = $this->findLocale($app, $lang);
+			$locale = $this->findLocale($lang);
 		}
 
 		if (!isset($this->instances[$lang][$app])) {

+ 1 - 1
lib/private/TemplateLayout.php

@@ -135,7 +135,7 @@ class TemplateLayout extends \OC_Template {
 		$lang = \OC::$server->getL10NFactory()->findLanguage();
 		$lang = str_replace('_', '-', $lang);
 		$this->assign('language', $lang);
-		$this->assign('locale', \OC::$server->getL10NFactory()->findLocale());
+		$this->assign('locale', \OC::$server->getL10NFactory()->findLocale($lang));
 
 		if(\OC::$server->getSystemConfig()->getValue('installed', false)) {
 			if (empty(self::$versionHash)) {