Fix/workaround for undfined constant GROCY_LOCALE

This commit is contained in:
Bernd Bestel 2020-11-08 21:37:43 +01:00
parent ea5b3dcd51
commit 0134535a5e
No known key found for this signature in database
GPG Key ID: 71BD34C0D4891300
2 changed files with 10 additions and 0 deletions

View File

@ -70,6 +70,11 @@ class BaseController
protected function getLocalizationService()
{
if (!defined('GROCY_LOCALE'))
{
define('GROCY_LOCALE', GROCY_DEFAULT_LOCALE);
}
return LocalizationService::getInstance(GROCY_LOCALE);
}

View File

@ -44,6 +44,11 @@ class BaseService
protected function getLocalizationService()
{
if (!defined('GROCY_LOCALE'))
{
define('GROCY_LOCALE', GROCY_DEFAULT_LOCALE);
}
return LocalizationService::getInstance(GROCY_LOCALE);
}