Skip to content
Snippets Groups Projects
Commit 1511c471 authored by Thijs Kinkhorst's avatar Thijs Kinkhorst
Browse files

SQLPermanent storage: expire: syntax fix IS (NOT) NULL

parent 9b0f3943
No related branches found
No related tags found
No related merge requests found
......@@ -186,7 +186,7 @@ class sspmod_core_Storage_SQLPermanentStorage
public function removeExpired()
{
$query = "DELETE FROM data WHERE expire NOT NULL AND expire < :expire";
$query = "DELETE FROM data WHERE expire IS NOT NULL AND expire < :expire";
$prepared = $this->db->prepare($query);
$data = array(':expire' => time());
$prepared->execute($data);
......@@ -209,7 +209,7 @@ class sspmod_core_Storage_SQLPermanentStorage
$conditions[] = "key2 = ".$this->db->quote($key2);
}
$conditions[] = "(expire = NULL OR expire >= ".time().")";
$conditions[] = "(expire IS NULL OR expire >= ".time().")";
return join(' AND ', $conditions);
}
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment