Commit 86876df5 authored by Darryl Hamilton's avatar Darryl Hamilton
Browse files

Patching XML Feed Reader 1.0.4 - adding $suppressWarnings fix (bug #750815)

(cherry picked from commit 48b8953c

)

Change-Id: I5dd34049292c7624220312d44496d64bc4cb4980
Signed-off-by: default avatarDarryl Hamilton <darrylh@catalyst.net.nz>
parent b039286b
......@@ -86,8 +86,13 @@ class XML_Feed_Parser implements Iterator
*/
function __construct($feed, $strict = false, $suppressWarnings = false, $tidy = false)
{
$options = 0;
if ($suppressWarnings) {
$options |= LIBXML_NOWARNING;
$options |= LIBXML_NOERROR;
}
$this->model = new DOMDocument;
if (! $this->model->loadXML($feed)) {
if (! $this->model->loadXML($feed, $options)) {
if (extension_loaded('tidy') && $tidy) {
$tidy = new tidy;
$tidy->parseString($feed,
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment