diff --git a/bot.php b/bot.php index 42a4723..6d51b2b 100644 --- a/bot.php +++ b/bot.php @@ -37,7 +37,11 @@ function ellipse($str,$n_chars,$crop_str='[...]') function formatdsc($description) { global $pandoc; $description = strip_tags($description, 'img'); - $description = $pandoc->convert($description, "html", "plain"); + $description = $pandoc->runWith($description, [ + 'from' => 'html', + 'to' => 'plain', + 'wrap' => 'none' + ]); $description = str_replace('Читать дальше', '', $description); $description = trim($description); return $description;