Commit 1fd77b3b authored by Michal Čihař's avatar Michal Čihař

Simplify code

Signed-off-by: default avatarMichal Čihař <michal@cihar.com>
parent 5ddbafd1
......@@ -117,14 +117,8 @@ class XMLTagsCheck(TargetCheck):
def check_highlight(self, source, unit):
ret = []
match_objects = XML_MATCH.finditer(source)
for match in match_objects:
if match.start() == match.end():
continue
for match in XML_MATCH.finditer(source):
ret.append((match.start(), match.group()))
match_objects = XML_ENTITY_MATCH.finditer(source)
for match in match_objects:
if match.start() == match.end():
continue
for match in XML_ENTITY_MATCH.finditer(source):
ret.append((match.start(), match.group()))
return ret
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