Skip to content

Commit

Permalink
fix: allow int value as DateTime param (#289)
Browse files Browse the repository at this point in the history
  • Loading branch information
simPod authored Jan 29, 2025
1 parent 88fa104 commit 9a90f8e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Param/ParamValueConverterRegistry.php
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,7 @@ private static function decimalConverter(): Closure

private static function dateConverter(): Closure
{
return static fn (DateTimeInterface|string|float $value) => $value instanceof DateTimeInterface
return static fn (DateTimeInterface|string|int|float $value) => $value instanceof DateTimeInterface
? $value->format('Y-m-d')
: $value;
}
Expand Down

0 comments on commit 9a90f8e

Please sign in to comment.