From 6b4819092cfb416348ef927fe62266a02a39baef Mon Sep 17 00:00:00 2001 From: root Date: Mon, 15 Oct 2012 03:30:12 +0100 Subject: [PATCH] fixed typo. the scrip should now work even after a reboot. --- door.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/door.sh b/door.sh index a168b81..9661a2a 100755 --- a/door.sh +++ b/door.sh @@ -8,7 +8,7 @@ CLOSED_INDICATOR=/tmp/door_status_closed if [ -f $OPEN_INDICATOR ]; then LOCK_AGE=$(( $(date +%s)-$(stat -c %X $OPEN_INDICATOR) )) -elif [ -f $CLOSE_INDICATOR ]; then +elif [ -f $CLOSED_INDICATOR ]; then LOCK_AGE=$(( $(date +%s)-$(stat -c %X $CLOSED_INDICATOR) )) else LOCK_AGE=15