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