diff --git a/modules/internet.sh b/modules/internet.sh index a3244a956..2e155e971 100644 --- a/modules/internet.sh +++ b/modules/internet.sh @@ -17,9 +17,9 @@ function internet { ip=$(echo "$info" | grep -e '"ip": "') org=$(echo "$info" | grep -e '"org": "') country=$(echo "$info" | grep -o '"country": "[^;]*') - city=$(echo $info | grep -o '"city": "[^;]*') - postal=$(echo $info | grep -o '"postal": "[^;]*') - timezone=$(echo $info | grep -o '"timezone": "[^;]*') + city=$(echo $info | grep -o '"city": "[^;]*' | cut -d ' ' -f 1,2) + postal=$(echo $info | grep -o '"postal": "[^;]*' | cut -d ' ' -f 1,2) + timezone=$(echo $info | grep -o '"timezone": "[^;]*' | cut -d ' ' -f 1,2) # echo " INFO: $info" # echo ""