##// END OF EJS Templates
minirst: don't choke on empty text
Matt Mackall -
r15123:9b41ccb2 default
parent child Browse files
Show More
@@ -38,6 +38,7 b' def findblocks(text):'
38 38 blocks = []
39 39 for b in _blockre.split(text.lstrip('\n').rstrip()):
40 40 lines = b.splitlines()
41 if lines:
41 42 indent = min((len(l) - len(l.lstrip())) for l in lines)
42 43 lines = [l[indent:] for l in lines]
43 44 blocks.append(dict(indent=indent, lines=lines))
General Comments 0
You need to be logged in to leave comments. Login now