]> git.wh0rd.org Git - tt-rss.git/commitdiff
rewrite_urls: try to workaround against some weird php-version related bug
authorAndrew Dolgov <fox@madoka.volgo-balt.ru>
Thu, 2 Feb 2012 08:46:07 +0000 (12:46 +0400)
committerAndrew Dolgov <fox@madoka.volgo-balt.ru>
Thu, 2 Feb 2012 08:46:07 +0000 (12:46 +0400)
include/functions.php

index f188fc10a8be7495fe611411aaf65b69483f2cfe..29f50f87689567649b77d9fafdf1c2f4a0456e7d 100644 (file)
 
                $node = $doc->getElementsByTagName('body')->item(0);
 
-               return $doc->saveXML($node);
+               // http://tt-rss.org/forum/viewtopic.php?f=1&t=970
+               if ($node)
+                       return $doc->saveXML($node);
+               else
+                       return $html;
        }
 
        function filter_to_sql($filter) {