diff --git a/src/Clock/Request.php b/src/Clock/Request.php index b9a4a8f..afe908d 100644 --- a/src/Clock/Request.php +++ b/src/Clock/Request.php @@ -4,6 +4,7 @@ namespace BradyMcD\TAATP\Clock; use DateTimeImmutable; +/** @SuppressWarnings(PHPMD.Superglobals)*/ class Request implements \Psr\Clock\ClockInterface { private $time; @@ -15,7 +16,7 @@ class Request implements \Psr\Clock\ClockInterface public function now(): DateTimeImmutable { - return new DateTimeImmutable($this->time); + return (new DateTimeImmutable())->setTimestamp($this->time); } }