File tree Expand file tree Collapse file tree 3 files changed +3
-3
lines changed Expand file tree Collapse file tree 3 files changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -22,7 +22,7 @@ final class MockClock implements ClockInterface
22
22
{
23
23
private \DateTimeImmutable $ now ;
24
24
25
- public function __construct (\DateTimeImmutable |string $ now = 'now ' , \DateTimeZone |string $ timezone = null )
25
+ public function __construct (\DateTimeImmutable |string $ now = 'now ' , \DateTimeZone |string | null $ timezone = null )
26
26
{
27
27
if (\is_string ($ timezone )) {
28
28
$ timezone = new \DateTimeZone ($ timezone );
Original file line number Diff line number Diff line change @@ -22,7 +22,7 @@ final class MonotonicClock implements ClockInterface
22
22
private int $ usOffset ;
23
23
private \DateTimeZone $ timezone ;
24
24
25
- public function __construct (\DateTimeZone |string $ timezone = null )
25
+ public function __construct (\DateTimeZone |string | null $ timezone = null )
26
26
{
27
27
if (false === $ offset = hrtime ()) {
28
28
throw new \RuntimeException ('hrtime() returned false: the runtime environment does not provide access to a monotonic timer. ' );
Original file line number Diff line number Diff line change @@ -20,7 +20,7 @@ final class NativeClock implements ClockInterface
20
20
{
21
21
private \DateTimeZone $ timezone ;
22
22
23
- public function __construct (\DateTimeZone |string $ timezone = null )
23
+ public function __construct (\DateTimeZone |string | null $ timezone = null )
24
24
{
25
25
if (\is_string ($ timezone ??= date_default_timezone_get ())) {
26
26
$ this ->timezone = new \DateTimeZone ($ timezone );
You can’t perform that action at this time.
0 commit comments