DbQuery: Return non-string args as is in `valueToTimestamp()`

fixes #4182
This commit is contained in:
Johannes Meyer 2020-06-18 15:13:11 +02:00
parent 4d173e6746
commit b288d86e91
1 changed files with 1 additions and 1 deletions

View File

@ -251,7 +251,7 @@ class DbQuery extends SimpleQuery
protected function valueToTimestamp($value) protected function valueToTimestamp($value)
{ {
// We consider integers as valid timestamps. Does not work for URL params // We consider integers as valid timestamps. Does not work for URL params
if (ctype_digit($value)) { if (! is_string($value) || ctype_digit($value)) {
return $value; return $value;
} }
$value = strtotime($value); $value = strtotime($value);