diff --git a/configs/appcfg/xinit_template b/configs/appcfg/xinit_template index 9694094..f95f147 100644 --- a/configs/appcfg/xinit_template +++ b/configs/appcfg/xinit_template @@ -25,9 +25,9 @@ amixer set "Line Out" 50% #mpv --quiet --no-video ~/welcome.ogg & # You will sometime get SMS or calls from not -# country code prefixed phone numbers. To ensure -# we match your contacts, we will use this one. -#export DEFAULT_NUMBER_PREFIX=+33 +# country code prefixed phone numbers. To make +# it easy to fixup configure the default countryu. +#export DEFAULT_COUNTRY=FR # turn on modemmonitor on login # Note: if the modemmonitor is not on you can diff --git a/scripts/core/sxmo_contactmenu.sh b/scripts/core/sxmo_contactmenu.sh index 02468e3..b4ab0ed 100755 --- a/scripts/core/sxmo_contactmenu.sh +++ b/scripts/core/sxmo_contactmenu.sh @@ -4,13 +4,13 @@ . "$(dirname "$0")/sxmo_common.sh" valid_number() { - if pn valid "$1"; then + if pn valid ${DEFAULT_COUNTRY:+-c "$DEFAULT_COUNTRY"} "$1"; then echo "$1" return fi REFORMATTED="$(pn find ${DEFAULT_COUNTRY:+-c "$DEFAULT_COUNTRY"} "$1")" - if pn valid "$REFORMATTED"; then + if pn valid ${DEFAULT_COUNTRY:+-c "$DEFAULT_COUNTRY"} "$REFORMATTED"; then echo "$REFORMATTED" return fi