gui-programs: don't disable wifi if hotspot on

This commit is contained in:
Antoine Martin 2022-03-06 16:44:42 +01:00
parent 4210e37496
commit 7e864564df

View file

@ -72,7 +72,9 @@ in
{ {
result=$(${nmcli} dev | ${grep} "ethernet" | ${grep} -w "connected") result=$(${nmcli} dev | ${grep} "ethernet" | ${grep} -w "connected")
if [ -n "$result" ]; then if [ -n "$result" ]; then
if ! ${nmcli} dev | ${grep} -q "hotspot"; then
${nmcli} radio wifi off ${nmcli} radio wifi off
fi
else else
${nmcli} radio wifi on ${nmcli} radio wifi on
fi fi