Commit 60b49356 authored by Michal Čihař's avatar Michal Čihař

Skip hightlight if check is disabled

Signed-off-by: default avatarMichal Čihař <michal@cihar.com>
parent 53478f8d
...@@ -206,6 +206,8 @@ class BaseFormatCheck(TargetCheck): ...@@ -206,6 +206,8 @@ class BaseFormatCheck(TargetCheck):
return False return False
def check_highlight(self, source, unit): def check_highlight(self, source, unit):
if self.should_skip(unit):
return []
ret = [] ret = []
match_objects = self.regexp.finditer(source) match_objects = self.regexp.finditer(source)
for match in match_objects: for match in match_objects:
......
...@@ -67,6 +67,8 @@ class BBCodeCheck(TargetCheck): ...@@ -67,6 +67,8 @@ class BBCodeCheck(TargetCheck):
return src_tags != tgt_tags return src_tags != tgt_tags
def check_highlight(self, source, unit): def check_highlight(self, source, unit):
if self.should_skip(unit):
return []
ret = [] ret = []
match_objects = BBCODE_MATCH.finditer(source) match_objects = BBCODE_MATCH.finditer(source)
for match in match_objects: for match in match_objects:
......
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