summaryrefslogtreecommitdiffstats
path: root/lib/Fetcher/FeedFetcher.php
diff options
context:
space:
mode:
Diffstat (limited to 'lib/Fetcher/FeedFetcher.php')
-rwxr-xr-xlib/Fetcher/FeedFetcher.php10
1 files changed, 8 insertions, 2 deletions
diff --git a/lib/Fetcher/FeedFetcher.php b/lib/Fetcher/FeedFetcher.php
index 8864df084..60d798889 100755
--- a/lib/Fetcher/FeedFetcher.php
+++ b/lib/Fetcher/FeedFetcher.php
@@ -114,15 +114,21 @@ class FeedFetcher implements IFeedFetcher
string $url,
bool $fullTextEnabled,
?string $user,
- ?string $password
+ ?string $password,
+ ?string $httpLastModified
): array {
$url2 = new Net_URL2($url);
if (!is_null($user) && trim($user) !== '') {
$url2->setUserinfo(rawurlencode($user), rawurlencode($password));
}
+ if (!is_null($httpLastModified) && trim($httpLastModified) !== '') {
+ $lastModified = new DateTime($httpLastModified);
+ } else {
+ $lastModified = null;
+ }
$url = $url2->getNormalizedURL();
$this->reader->resetFilters();
- $resource = $this->reader->read($url);
+ $resource = $this->reader->read($url, null, $lastModified);
$location = $resource->getUrl();
$parsedFeed = $resource->getFeed();