Switch from DateTime to DateTimeImmutable across codebase

This commit is contained in:
Alex Cabal 2024-04-13 14:05:14 -05:00
parent 92c647f2b1
commit e55fecaaa2
35 changed files with 102 additions and 99 deletions

View file

@ -1,5 +1,5 @@
<?
use Safe\DateTime;
use Safe\DateTimeImmutable;
use function Safe\fopen;
use function Safe\fwrite;
use function Safe\fclose;
@ -33,7 +33,7 @@ class Log{
return;
}
$now = new DateTime('now', new DateTimeZone('UTC'));
$now = new DateTimeImmutable();
fwrite($fp, $now->format('Y-m-d H:i:s') . "\t" . $this->RequestId . "\t" . $text . "\n");
fclose($fp);