From ca0842ccf8f0c3990f3d55731d60a9921a573405 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pierre=20Mazi=C3=A8re?= Date: Thu, 15 Sep 2016 12:34:07 +0200 Subject: [PATCH] [FeedExpander] widen guid use as uri provider MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Pierre Mazière --- lib/FeedExpander.php | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lib/FeedExpander.php b/lib/FeedExpander.php index 38b6ad0..46caed1 100644 --- a/lib/FeedExpander.php +++ b/lib/FeedExpander.php @@ -153,7 +153,10 @@ abstract class FeedExpander extends BridgeAbstract { if(isset($feedItem->guid)){ foreach($feedItem->guid->attributes() as $attribute=>$value){ - if($attribute === 'isPermaLink' && $value === "true"){ + if($attribute === 'isPermaLink' && ( + $value === 'true' || + filter_var($feedItem->guid,FILTER_VALIDATE_URL) + )){ $item['uri'] = $feedItem->guid; break; }