X-Git-Url: https://git.ao2.it/tweeper.git/blobdiff_plain/c00b4af91e650a23612cf94067606ec5851e6204..db2757cc107da3869ce3cc930038ae0963a2b8d7:/src/Tweeper.php diff --git a/src/Tweeper.php b/src/Tweeper.php index 8ac2fe3..d60e43b 100644 --- a/src/Tweeper.php +++ b/src/Tweeper.php @@ -249,7 +249,10 @@ class Tweeper { return NULL; } - return Tweeper::jsonToXml($matches[1], 'instagram'); + // Filter elements which will result in invalid XML element names. + $json = str_replace('404_as_react', '_404_as_react', $matches[1]); + + return Tweeper::jsonToXml($json, 'instagram'); } /**