From 71bfcbba8e2b1702b53f27e7c06ff4ad73ce9b2f Mon Sep 17 00:00:00 2001 From: Erik Friberg Date: Sun, 11 Feb 2024 23:54:08 +0100 Subject: [PATCH 1/2] replaced deprecated contentFile() method --- src/feeds.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/feeds.php b/src/feeds.php index f03a860..70709ca 100644 --- a/src/feeds.php +++ b/src/feeds.php @@ -381,9 +381,9 @@ private static function getDatesFromPage(Page $p, int &$whenMod, int &$whenPub): $t = $p->content()->get('date'); $whenMod = strtotime($t); } else { - if (file_exists($p->contentFile())) { - $mtime = filemtime($p->contentFile()); - $ctime = filectime($p->contentFile()); + if (file_exists($p->->storage()->contentFile())) { + $mtime = filemtime($p->storage()->contentFile()); + $ctime = filectime($p->storage()->contentFile()); $whenMod = max($mtime, $ctime); } } From 6626c105e67062efb8a43147696b9ad535e9c13b Mon Sep 17 00:00:00 2001 From: Erik Friberg Date: Mon, 12 Feb 2024 00:05:59 +0100 Subject: [PATCH 2/2] New argument requirements for substitue functions --- src/feeds.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/feeds.php b/src/feeds.php index 70709ca..dc97154 100644 --- a/src/feeds.php +++ b/src/feeds.php @@ -381,9 +381,9 @@ private static function getDatesFromPage(Page $p, int &$whenMod, int &$whenPub): $t = $p->content()->get('date'); $whenMod = strtotime($t); } else { - if (file_exists($p->->storage()->contentFile())) { - $mtime = filemtime($p->storage()->contentFile()); - $ctime = filectime($p->storage()->contentFile()); + if (file_exists($p->storage()->contentFile('published', 'default'))) { + $mtime = filemtime($p->storage()->contentFile('published', 'default')); + $ctime = filectime($p->storage()->contentFile('published', 'default')); $whenMod = max($mtime, $ctime); } }