diff --git a/lib/FeedExpander.php b/lib/FeedExpander.php index b9443caf..a5a55814 100644 --- a/lib/FeedExpander.php +++ b/lib/FeedExpander.php @@ -66,23 +66,7 @@ abstract class FeedExpander extends BridgeAbstract '»', '’', ]; - $xmlString = str_replace($problematicStrings, '', $xmlString); - - // Remove extra content at the end of the document, if any (#4485) - // First retrieve tag name of root node, which is the first node following in xml string and strip anything beyond that. - if (preg_match('/(?:<\?xml[^>]*\?>[^<]*<)([^ "\'>]+)/i', $xmlString, $matches) === 1) { - $root_node_tag = $matches[1]; - $last_closing_occurrence = strripos($xmlString, '', $last_closing_occurrence); - if ($closing_node_end !== false) { - $xmlString = substr($xmlString, 0, $closing_node_end + 1); - } - } - } - - return $xmlString; + return str_replace($problematicStrings, '', $xmlString); } public function getURI()