Quit earlier in ProbeURL->getFeedLink if body is empty
This commit is contained in:
parent
995d53ebfc
commit
77b24a0b66
1 changed files with 2 additions and 1 deletions
|
@ -1754,10 +1754,11 @@ class Probe
|
||||||
*/
|
*/
|
||||||
public static function getFeedLink(string $url, string $body)
|
public static function getFeedLink(string $url, string $body)
|
||||||
{
|
{
|
||||||
$doc = new DOMDocument();
|
|
||||||
if (empty($body)) {
|
if (empty($body)) {
|
||||||
return '';
|
return '';
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$doc = new DOMDocument();
|
||||||
if (!@$doc->loadHTML($body)) {
|
if (!@$doc->loadHTML($body)) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue