diff --git a/lib/mfrc522/source/loop.php b/lib/mfrc522/source/loop.php index 5841cd8..bb49c59 100755 --- a/lib/mfrc522/source/loop.php +++ b/lib/mfrc522/source/loop.php @@ -139,8 +139,10 @@ } /* (4) If no action found -> abort */ - if( count($grantedFor) == 0 ) + if( count($grantedFor) == 0 ){ + slog('user not granted to any action', 'mfrc522:loop'); return false; + } /* [4] Manage action depending on the actual STATE @@ -178,8 +180,10 @@ } /* (6) If no action cant be performed -> abort */ - if( is_null($toPerform) ) + if( is_null($toPerform) ){ + slog('global state allows no action to be performed', 'mfrc522:loop'); return false; + } /* (7) Extract corresponding action */ $action = $grantedFor[$toPerform];