From 1f05c923762a7f395cbb9c63121445f0e688a076 Mon Sep 17 00:00:00 2001 From: Alexandre Alapetite Date: Wed, 19 Jul 2023 23:40:28 +0200 Subject: Fix enclosures in RSS output (#5540) * Fix enclosures in RSS output fix https://github.com/FreshRSS/FreshRSS/issues/5539 * another iterable * Forgotten iterable --- app/Models/Entry.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'app/Models/Entry.php') diff --git a/app/Models/Entry.php b/app/Models/Entry.php index 7e10367fa..77f39f256 100644 --- a/app/Models/Entry.php +++ b/app/Models/Entry.php @@ -235,12 +235,12 @@ HTML; /** @return Traversable}> */ public function enclosures(bool $searchBodyImages = false): Traversable { $attributeEnclosures = $this->attributes('enclosures'); - if (is_array($attributeEnclosures)) { + if (is_iterable($attributeEnclosures)) { // FreshRSS 1.20.1+: The enclosures are saved as attributes yield from $attributeEnclosures; } try { - $searchEnclosures = !is_array($attributeEnclosures) && (strpos($this->content, '

content, '