From 800fe77b64b224ee32b33685b1a7f82c0bf8246a Mon Sep 17 00:00:00 2001 From: CodeShakingSheep <19874562+CodeShakingSheep@users.noreply.github.com> Date: Fri, 9 Feb 2024 14:35:46 +0100 Subject: [PATCH] Update upgrade Fix setting default phone region --- scripts/upgrade | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/scripts/upgrade b/scripts/upgrade index a5c250a..c90efd9 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -143,7 +143,8 @@ then # Fix warning "Your installation has no default phone region set" if [ "$(exec_occ config:system:get default_phone_region)" == "" ]; then config_locale=$(exec_occ config:system:get default_locale) - exec_occ config:system:set default_phone_region --value="$config_locale" + country=$(echo "$config_locale" | awk -F'_' '{print $2}') + exec_occ config:system:set default_phone_region --value="$country" fi # Upgrade may fail if this app is enabled