mirror of
https://github.com/RSS-Bridge/rss-bridge.git
synced 2025-01-16 13:50:01 +01:00
fix(FeedParser): dont emit content module (#4180)
This commit is contained in:
parent
8a1f2604aa
commit
615c533587
@ -197,9 +197,6 @@ class FeedItem
|
||||
|| $content instanceof simple_html_dom_node
|
||||
) {
|
||||
$content = (string) $content;
|
||||
} elseif (is_array($content)) {
|
||||
// Assuming this is the rss2.0 content module
|
||||
$content = $content['encoded'] ?? '';
|
||||
}
|
||||
|
||||
if (is_string($content)) {
|
||||
|
@ -168,8 +168,13 @@ final class FeedParser
|
||||
$media = $feedItem->children($namespaces['media']);
|
||||
}
|
||||
|
||||
if (isset($namespaces['content'])) {
|
||||
$content = $feedItem->children($namespaces['content']);
|
||||
$item['content'] = (string) $content;
|
||||
}
|
||||
|
||||
foreach ($namespaces as $namespaceName => $namespaceUrl) {
|
||||
if (in_array($namespaceName, ['', 'media'])) {
|
||||
if (in_array($namespaceName, ['', 'content', 'media'])) {
|
||||
continue;
|
||||
}
|
||||
$item[$namespaceName] = $this->parseModule($feedItem, $namespaceName, $namespaceUrl);
|
||||
|
Loading…
x
Reference in New Issue
Block a user