mirror of
https://github.com/ZoneMinder/zoneminder.git
synced 2026-10-24 07:18:22 -04:00
IN () being false could still result in a true result of used in an OR, so instead of just returning, use an always false sql equivalent
This commit is contained in:
1 parent
837d0ece7f
commit
ff01d4d394
1 file changed
+1
-2
@@ -103,9 +103,8 @@ class ZM_Object {
|
||||
$fields[] = '`'.$field.'` IN ('.implode(',', array_map($func, $value)). ')';
|
||||
$values += $value;
|
||||
} else {
|
||||
return array();
|
||||
$fields[] = '`'.$field'` IN (select top 0 0)'; # evaluates to false
|
||||
}
|
||||
|
||||
} else {
|
||||
$fields[] = '`'.$field.'`=?';
|
||||
$values[] = $value;
|
||||
|
||||
Reference in new issue
Block a user