Allow int for float filter queries

This commit is contained in:
Jake Barnby 2023-03-30 21:02:33 +13:00
parent 39acf18bc3
commit bd64ace713
No known key found for this signature in database
GPG key ID: C437A8CC85B96E9C

View file

@ -75,6 +75,7 @@ class Filter extends Base
$condition = match ($attributeType) {
Database::VAR_RELATIONSHIP => true,
Database::VAR_DATETIME => gettype($value) === Database::VAR_STRING,
Database::VAR_FLOAT => (gettype($value) === Database::VAR_FLOAT || gettype($value) === Database::VAR_INTEGER),
default => gettype($value) === $attributeType
};