diff --git a/usr/share/biglinux/biglinux-settings/devices/bluetooth.sh b/usr/share/biglinux/biglinux-settings/devices/bluetooth.sh index fa1dc41..13a09d4 100755 --- a/usr/share/biglinux/biglinux-settings/devices/bluetooth.sh +++ b/usr/share/biglinux/biglinux-settings/devices/bluetooth.sh @@ -3,7 +3,9 @@ # check current status # action=$1 if [ "$1" == "check" ]; then - bluetoothState="$(LANG=C LANGUAGE=C timeout 0.1 echo "show" | bluetoothctl | grep "Powered:" | awk '{print $2}')" + set -o pipefail + bluetoothState="$(LANG=C LANGUAGE=C echo "show" | timeout 0.1 bluetoothctl | grep "Powered:" | awk '{print $2}')" + set +o pipefail if [[ "$bluetoothState" == "yes" ]];then echo "true" else