Forums
(@rlpenasp)
4 years, 3 months ago
This error isn’t new. – https://github.com/Automattic/facebook-instant-articles-wp/issues/1030 – https://github.com/Automattic/facebook-instant-articles-wp/issues/989
I’ve made a workaround testing if de method exists.
$clone = null; if(method_exists($node, ‘cloneNode’)){ $clone = $node->cloneNode(true); if (isset($clone) && Type::is($clone, ‘DOMElement’) && $clone->hasAttribute(self::INSTANT_ARTICLES_PARSED_FLAG)) { $clone->removeAttribute(self::INSTANT_ARTICLES_PARSED_FLAG); } } return $clone;
I have the same problem here.