mirror of
https://github.com/standardebooks/web.git
synced 2025-07-14 18:42:00 -04:00
Switch from DateTime to DateTimeImmutable across codebase
This commit is contained in:
parent
92c647f2b1
commit
e55fecaaa2
35 changed files with 102 additions and 99 deletions
|
@ -1,5 +1,5 @@
|
|||
<?
|
||||
use Safe\DateTime;
|
||||
use Safe\DateTimeImmutable;
|
||||
use function Safe\file_get_contents;
|
||||
use function Safe\filesize;
|
||||
use function Safe\preg_replace;
|
||||
|
@ -27,7 +27,7 @@ class RssFeed extends Feed{
|
|||
|
||||
protected function GetXmlString(): string{
|
||||
if($this->XmlString === null){
|
||||
$feed = Template::RssFeed(['url' => $this->Url, 'description' => $this->Description, 'title' => $this->Title, 'entries' => $this->Entries, 'updated' => (new DateTime())->format('r')]);
|
||||
$feed = Template::RssFeed(['url' => $this->Url, 'description' => $this->Description, 'title' => $this->Title, 'entries' => $this->Entries, 'updated' => (new DateTimeImmutable())->format('r')]);
|
||||
|
||||
$this->XmlString = $this->CleanXmlString($feed);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue