Skip to content

Commit 3f1e0d7

Browse files
authored
Suppress libxml2 errors
1 parent b287dbd commit 3f1e0d7

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/Parsers/HtmlParser.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -155,10 +155,10 @@ protected function xpath(): DOMXPath
155155
{
156156
if(!isset($this->xpath)) {
157157
$document = new DOMDocument;
158-
$document->loadHTML(str_replace(["\r\n","\n"], "", $this->contents));
158+
$document->loadHTML(str_replace(["\r\n","\n"], "", $this->contents), LIBXML_NOERROR);
159159
$this->xpath = new DOMXpath($document);
160160
}
161161

162162
return $this->xpath;
163163
}
164-
}
164+
}

0 commit comments

Comments
 (0)