Skip to content
Snippets Groups Projects
Commit 03ec85b9 authored by Simon Heimberg's avatar Simon Heimberg
Browse files

minirst: do not fail on an empty admonition block

parent 8ac7b85b
No related branches found
No related tags found
No related merge requests found
......@@ -453,6 +453,8 @@
indent = ' ' * block['indent']
if block['type'] == 'admonition':
admonition = _admonitiontitles[block['admonitiontitle']]
if not block['lines']:
return indent + admonition + '\n'
hang = len(block['lines'][-1]) - len(block['lines'][-1].lstrip())
defindent = indent + hang * ' '
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment