mirror of
https://github.com/olivierkes/manuskript.git
synced 2024-05-17 11:22:28 +12:00
Fixes a bug in highlighter that makes it slow
This commit is contained in:
parent
2b1465a1f3
commit
91989269f1
|
@ -260,7 +260,7 @@ class MarkdownTokenizer(HighlightTokenizer):
|
|||
else:
|
||||
# Restart tokenizing on the previous line.
|
||||
self.requestBacktrack()
|
||||
False
|
||||
return False
|
||||
|
||||
return False
|
||||
|
||||
|
@ -450,7 +450,6 @@ class MarkdownTokenizer(HighlightTokenizer):
|
|||
MS.MarkdownStateBlockquote,
|
||||
MS.MarkdownStateNumberedList,
|
||||
MS.MarkdownStateBulletPointList,]:
|
||||
self.requestBacktrack()
|
||||
if self.lineBreakRegex.exactMatch(text):
|
||||
token = Token()
|
||||
token.type = MTT.TokenLineBreak
|
||||
|
|
Loading…
Reference in a new issue