sleepwalk: Call systemctl only if rctwake succeeds

This commit is contained in:
Xavier Del Campo Romero 2023-10-03 20:11:00 +02:00
parent 451b33d984
commit bf00cb71c8
Signed by: xavi
GPG Key ID: 84FF3612A9BF43F2
1 changed files with 1 additions and 2 deletions

View File

@ -78,8 +78,7 @@ while :
do
if can_suspend
then
rtcwake -m no -s 600 || :
systemctl suspend
(rtcwake -m no -s 600 && systemctl suspend) || :
if can_suspend
then