From a551943b49558e4df35c9aded72674104d9257bf Mon Sep 17 00:00:00 2001 From: RealStickman Date: Fri, 2 Jun 2023 17:41:24 +0200 Subject: [PATCH] remove newline --- plugins/shortcode-custom/Prismjsshroot.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/shortcode-custom/Prismjsshroot.php b/plugins/shortcode-custom/Prismjsshroot.php index 3eda12a..6969207 100644 --- a/plugins/shortcode-custom/Prismjsshroot.php +++ b/plugins/shortcode-custom/Prismjsshroot.php @@ -8,7 +8,7 @@ class Prismjsshroot extends Shortcode public function init() { $this->shortcode->getRawHandlers()->add('shroot', function(ShortcodeInterface $sc) { - $content = preg_replace('/^```.*$/m', '', $content); + $content = preg_replace('/^```.*(\n)?$/m', '', $content); $content = trim($sc->getContent(), "\n "); return '
'.$content.'
'; });