summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPhil Davis <phil@jankaritech.com>2017-04-29 23:08:00 +0545
committerjim-p <jimp@pfsense.org>2017-05-02 10:41:33 -0400
commit7b492a56dd0737e24cca701d344002432d7adbe7 (patch)
treef3960fa8a55fc1ee5d0acb5ace3743fca13e1a54
parent443ef349b8442eab2d2ad06dfffe5d5426c1337b (diff)
downloadpfsense-7b492a56dd0737e24cca701d344002432d7adbe7.zip
pfsense-7b492a56dd0737e24cca701d344002432d7adbe7.tar.gz
Set default anguage in General Setup to en_US
Since https://github.com/pfsense/pfsense/commit/fdcde31b4a910c4e058513c1e3f68a62e722da6b added German to the top of the get_locale_list() array, if you start with a default system and go to System->General Setup (make some changes to other fields if you like) and press Save, you end up in German because that is what gets selected in the dropdown when the config does not yet have a language in it. The code assumed that the language of the default system is the language at the top of the list, which is no longer true.
-rw-r--r--src/usr/local/www/system.php5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/usr/local/www/system.php b/src/usr/local/www/system.php
index e0604df..166853a 100644
--- a/src/usr/local/www/system.php
+++ b/src/usr/local/www/system.php
@@ -79,6 +79,11 @@ if (!isset($config['system']['webgui']['dashboardcolumns'])) {
$config['system']['webgui']['dashboardcolumns'] = 2;
}
+// set default language if unset
+if (!isset($config['system']['language'])) {
+ $config['system']['language'] = 'en_US';
+}
+
$dnsgw_counter = 1;
while (isset($config["system"]["dns{$dnsgw_counter}gw"])) {
OpenPOWER on IntegriCloud