Update RedditBridge.php (#4019)

prevent error htmlspecialchars_decode(): Passing null to parameter #1
This commit is contained in:
Tone 2024-03-17 19:02:51 +01:00 committed by GitHub
parent 36147a082d
commit a61524bf77
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -189,7 +189,7 @@ class RedditBridge extends BridgeAbstract
// Comment
$item['content'] = htmlspecialchars_decode($data->body_html);
} elseif ($data->is_self) {
} elseif ($data->is_self && isset($data->selftext_html)) {
// Text post
$item['content'] = htmlspecialchars_decode($data->selftext_html);