- Continued work on SearchRequest migration and fixed some more QueryBuilder migration too
This commit is contained in:
1 parent
9fdebf454d
commit
950df5eb99
15 files changed
+122
-48
No files matched your search
@@ -507,6 +507,15 @@ class MysqlQueryBuilder extends SqlQueryBuilder
|
||||
$key = ":p" . $this->parameterIndex++;
|
||||
}
|
||||
|
||||
if ($value instanceof \UnitEnum) {
|
||||
if ($value instanceof \BackedEnum) {
|
||||
$value = $value->value;
|
||||
}
|
||||
else {
|
||||
throw new \InvalidArgumentException("Using UnitEnum as a parameter is currently unsupported. Try using a BackedEnum instead.");
|
||||
}
|
||||
}
|
||||
|
||||
$this->parameters[$key] = $value;
|
||||
|
||||
return $key;
|
||||
|
||||
Reference in new issue
Block a user