[FurAffinity] fix: errror (#2887)

They changed parts of the dom.

Fix error:
Error: Call to a member function find() on null

Fixes #2868
This commit is contained in:
Dag 2022-07-10 19:48:37 +02:00 committed by GitHub
parent 87f8571ccf
commit 003ab58514
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 7 additions and 4 deletions

View File

@ -914,10 +914,13 @@ class FurAffinityBridge extends BridgeAbstract
$imgURL = 'https:' . $previewSrc;
}
$description = $submissionHTML
->find('.maintable .maintable tr td.alt1', -1);
$description = $submissionHTML->find('div.submission-description', 0);
if ($description) {
$this->setReferrerPolicy($description);
$description = $description->innertext;
$description = trim($description->innertext);
} else {
$description = '';
}
$item['content'] = <<<EOD
<a href="$submissionURL">