From b01d8293db978fa72220f10c4f0bb7f9eced1fd0 Mon Sep 17 00:00:00 2001 From: DL6ER Date: Tue, 20 Dec 2016 21:40:19 +0100 Subject: [PATCH] Improved comments --- data.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/data.php b/data.php index dd5c5c5b..43ba51e6 100644 --- a/data.php +++ b/data.php @@ -279,14 +279,14 @@ // (e.g. once in gravity list, once in blacklist) if($action && strlen($key) > 0) { + // $action is true (we want to add) *and* key is not empty $array[$key] = true; } - elseif(isset($array[$key])) + elseif(!$action && isset($array[$key])) { - // $action is not true (we want to remove) *and* key is set + // $action is false (we want to remove) *and* key is set unset($array[$key]); } - // else: Remove, but not set -> don't have to don anything } }