From cf6e716301713b96d30293af55a6cadd83580a81 Mon Sep 17 00:00:00 2001 From: mwiegand Date: Sat, 12 Feb 2022 20:40:14 +0100 Subject: [PATCH] fix if --- bundles/wol-sleeper/files/suspend_if_idle | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bundles/wol-sleeper/files/suspend_if_idle b/bundles/wol-sleeper/files/suspend_if_idle index c3b50fb..99434d9 100644 --- a/bundles/wol-sleeper/files/suspend_if_idle +++ b/bundles/wol-sleeper/files/suspend_if_idle @@ -22,7 +22,7 @@ do done LOGINS=$(who -u | grep pts\/ | wc -l) -if ! [[ "$LOGINS" =~ "^0$" ]] +if [[ "$LOGINS" -gt 0 ]] then echo "ABORT: $LOGINS user logins" exit 0