]> git.mxchange.org Git - quix0rs-gnu-social.git/blob - plugins/FeedSub/extlib/xml-feed-parser-bug-16416.patch
Initial functional version of feed subscription plugin, currently supporting only...
[quix0rs-gnu-social.git] / plugins / FeedSub / extlib / xml-feed-parser-bug-16416.patch
1 diff --git a/htdocs/lib/pear/XML/Feed/Parser/RSS2.php b/htdocs/lib/pear/XML/Feed/Parser/RSS2.php
2 index c5d79d1..308a4ab 100644
3 --- a/htdocs/lib/pear/XML/Feed/Parser/RSS2.php
4 +++ b/htdocs/lib/pear/XML/Feed/Parser/RSS2.php
5 @@ -321,7 +321,8 @@ class XML_Feed_Parser_RSS2 extends XML_Feed_Parser_Type
6       */
7      function getLink($offset, $attribute = 'href', $params = array())
8      {
9 -        $links = $this->model->getElementsByTagName('link');
10 +        $xPath = new DOMXPath($this->model);
11 +        $links = $xPath->query('//link');
12  
13          if ($links->length <= $offset) {
14              return false;