summaryrefslogtreecommitdiffstats
path: root/lib/locale.sh
diff options
context:
space:
mode:
Diffstat (limited to 'lib/locale.sh')
-rw-r--r--lib/locale.sh8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/locale.sh b/lib/locale.sh
index 3f33b67..da2e4d6 100644
--- a/lib/locale.sh
+++ b/lib/locale.sh
@@ -38,10 +38,10 @@ oh_locale_set()
fi
# Try to load the locale.
- if [ -f "@@LOCALEDIR@@/${_locale%.}" ]; then
- . "@@LOCALEDIR@@/${_locale%.}"
- elif [ -f "@@LOCALEDIR@@/${_locale%_}" ]; then
- . "@@LOCALEDIR@@/${_locale%_}"
+ if [ -f "@@LOCALEDIR@@/${_locale%.*}" ]; then
+ . "@@LOCALEDIR@@/${_locale%.*}"
+ elif [ -f "@@LOCALEDIR@@/${_locale%_*}" ]; then
+ . "@@LOCALEDIR@@/${_locale%_*}"
else
. @@LOCALEDIR@@/en_US
fi