[status] fix: pipe errors to /dev/null if iface is missing
This commit is contained in:
parent
0c8623b510
commit
abf306c99f
@ -18,7 +18,7 @@ case "$state" in
|
||||
INTERFACE_DISABLED) str="WIFI DOWN" ;;
|
||||
*) str="$(printf "NO WIFI")";;
|
||||
esac
|
||||
eth="$(cat /sys/class/net/enp0s31f6/operstate)"
|
||||
eth="$(cat /sys/class/net/enp0s31f6/operstate &> /dev/null)"
|
||||
if [ "up" = "$eth" ]; then
|
||||
str="$(printf "%s / " "$str")"
|
||||
fi
|
||||
|
Reference in New Issue
Block a user