From 2ff190798351033cdc31376c6c9aa0e08d55996d Mon Sep 17 00:00:00 2001 From: Sabina Talipova Date: Wed, 20 Sep 2023 14:55:54 +1200 Subject: [PATCH] MNT Move i18n::default_locale value in to config.yml --- _config.php | 6 ------ _config/config.yml | 9 +++++++++ 2 files changed, 9 insertions(+), 6 deletions(-) diff --git a/_config.php b/_config.php index 470a726..2272384 100644 --- a/_config.php +++ b/_config.php @@ -11,12 +11,6 @@ use SilverStripe\Core\Environment; use SilverStripe\HybridSessions\HybridSession; -use SilverStripe\i18n\i18n; - -// set the system locale to en_GB. This also means locale dropdowns -// and date formatting etc will default to this locale. Note there is no -// English (New Zealand) option -i18n::set_locale('en_GB'); // default to the binary being in the usual path on Linux if (!Environment::getEnv('WKHTMLTOPDF_BINARY')) { diff --git a/_config/config.yml b/_config/config.yml index 6aa5a2a..e7e1982 100644 --- a/_config/config.yml +++ b/_config/config.yml @@ -31,3 +31,12 @@ SilverStripe\Core\Injector\Injector: GDBackend: default_quality: 90 + +# Set the system locale to en_GB. This also means locale dropdowns +# and date formatting etc will default to this locale. Note there is no +# English (New Zealand) option +--- +Name: cwplocaleconfig +--- +SilverStripe\i18n\i18n: + default_locale: en_GB