From da58b894a4239e95342524eeacb85af7bf6c5a9d Mon Sep 17 00:00:00 2001 From: Daniel Siepmann Date: Tue, 17 Jan 2023 07:17:01 +0100 Subject: [PATCH] Properly handle feed item creation date with surrounding whitespace Some feeds might have whitespace around the creation date. This can't be parsed by DateTimeFormat methods. Therefore the incoming creation date is trimmed to not contain any surrounding whitespace for proper handling. Relates: #12686 --- src/Protocol/Feed.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Protocol/Feed.php b/src/Protocol/Feed.php index ccbe35e712..be58b9aa8f 100644 --- a/src/Protocol/Feed.php +++ b/src/Protocol/Feed.php @@ -376,11 +376,11 @@ class Feed } if ($published != '') { - $item['created'] = $published; + $item['created'] = trim($published); } if ($updated != '') { - $item['edited'] = $updated; + $item['edited'] = trim($updated); } if (!$dryRun) {