Log the feed fix only if it has an effect.

This commit is contained in:
Michael 2024-05-12 00:32:24 +00:00
parent 9e1362ba46
commit 52b11856fa

View file

@ -547,9 +547,11 @@ class Feed
}
if (!HTML::isHTML($body)) {
$original = $body;
$body = BBCode::convert($body, false, BBCode::EXTERNAL);
Logger::debug('Body contained no HTML', ['original' => $original, 'converted' => $body]);
$html = BBCode::convert($body, false, BBCode::EXTERNAL);
if ($body != $html) {
Logger::debug('Body contained no HTML', ['original' => $body, 'converted' => $html]);
$body = $html;
}
}
$item['body'] = HTML::toBBCode($body, $basepath);