mirror of
https://github.com/nextcloud/server.git
synced 2026-04-21 14:23:17 -04:00
Merge pull request #54230 from nextcloud/bugfix/spreed-15625/log-query-with-immutable-dates
fix(logging): Fix query logging with DateTimeImmutable parameters
This commit is contained in:
commit
c9fa1db925
1 changed files with 1 additions and 1 deletions
|
|
@ -161,7 +161,7 @@ class QueryBuilder implements IQueryBuilder {
|
|||
try {
|
||||
$params = [];
|
||||
foreach ($this->getParameters() as $placeholder => $value) {
|
||||
if ($value instanceof \DateTime) {
|
||||
if ($value instanceof \DateTimeInterface) {
|
||||
$params[] = $placeholder . ' => DateTime:\'' . $value->format('c') . '\'';
|
||||
} elseif (is_array($value)) {
|
||||
$params[] = $placeholder . ' => (\'' . implode('\', \'', $value) . '\')';
|
||||
|
|
|
|||
Loading…
Reference in a new issue