Commit f0fbdaa6 authored by Emanuil Rusev's avatar Emanuil Rusev
Browse files

backtick within code span

parent e20c0a29
......@@ -948,9 +948,9 @@ class Parsedown
case '`':
if (preg_match('/^`(.+?)`/', $text, $matches))
if (preg_match('/^(`+)(.+?)\1(?!`)/', $text, $matches))
$element_text = $matches[1];
$element_text = $matches[2];
$element_text = htmlspecialchars($element_text, ENT_NOQUOTES, 'UTF-8');
$markup .= '<code>'.$element_text.'</code>';
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment