diff options
author | VirtualTam <virtualtam@flibidi.net> | 2017-01-06 18:54:29 +0100 |
---|---|---|
committer | VirtualTam <virtualtam+github@flibidi.net> | 2017-01-07 14:37:40 +0100 |
commit | ee6f4b64a91d76070f930cdf7602ab4686714c7a (patch) | |
tree | 29056ef186c14a08d9ce7e1aa7514fa98bd2197e /index.php | |
parent | 7418f7cb60524c3bfc2f240386b5e3e7eb9b3257 (diff) | |
download | Shaarli-ee6f4b64a91d76070f930cdf7602ab4686714c7a.tar.gz Shaarli-ee6f4b64a91d76070f930cdf7602ab4686714c7a.tar.zst Shaarli-ee6f4b64a91d76070f930cdf7602ab4686714c7a.zip |
Cleanup: use safe boolean comparisons
Signed-off-by: VirtualTam <virtualtam@flibidi.net>
Diffstat (limited to 'index.php')
-rw-r--r-- | index.php | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -204,7 +204,7 @@ function setup_login_state($conf) | |||
204 | } | 204 | } |
205 | // If session does not exist on server side, or IP address has changed, or session has expired, logout. | 205 | // If session does not exist on server side, or IP address has changed, or session has expired, logout. |
206 | if (empty($_SESSION['uid']) | 206 | if (empty($_SESSION['uid']) |
207 | || ($conf->get('security.session_protection_disabled') == false && $_SESSION['ip'] != allIPs()) | 207 | || ($conf->get('security.session_protection_disabled') === false && $_SESSION['ip'] != allIPs()) |
208 | || time() >= $_SESSION['expires_on']) | 208 | || time() >= $_SESSION['expires_on']) |
209 | { | 209 | { |
210 | logout(); | 210 | logout(); |