fix: filter column value null in where method

This commit is contained in:
Victor Westerlund 2023-12-31 17:30:50 +01:00
parent c1c67d0267
commit 1b37a63c34

View file

@ -91,6 +91,12 @@
continue;
}
// Value is null so it does not need to be added to the prepared statement
if (is_null($value)) {
$filter[] = "`{$col}` IS NULL";
continue;
}
// Create SQL for prepared statement
$filter[] = "`{$col}` = ?";
// Append value to array with all other values