forked from kate/uniborg
clean up parser
This commit is contained in:
parent
969da5bcc9
commit
edd042190d
|
@ -63,8 +63,10 @@ def parse(message):
|
|||
match = pattern.match(message, pos=i)
|
||||
if match:
|
||||
break
|
||||
else:
|
||||
i += 1
|
||||
continue
|
||||
|
||||
if match:
|
||||
text, entity = parser(match)
|
||||
# replace whole match with text from parser
|
||||
message = ''.join((
|
||||
|
@ -79,9 +81,6 @@ def parse(message):
|
|||
|
||||
# skip past the match
|
||||
i += len(text)
|
||||
continue
|
||||
|
||||
i += 1
|
||||
|
||||
return _del_surrogate(message), entities
|
||||
|
||||
|
|
Loading…
Reference in New Issue