Skip to content

Commit

Permalink
wmllint: fixed a regex that didn't match augmentation tags
Browse files Browse the repository at this point in the history
(cherry-picked from commit cc178ad)
  • Loading branch information
Elvish-Hunter committed Oct 7, 2018
1 parent 8b32f89 commit 4b81eb5
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion data/tools/wmllint
Expand Up @@ -1719,7 +1719,9 @@ def global_sanity_check(filename, lines):
elif "[/multiplayer]" in lines[i]:
in_multiplayer = False
else:
if re.search(r"\[[a-z]", lines[i]):
# the + check is needed for augmentation tags
# otherwise subtag_depth may become negative
if re.search(r"\[\+?[a-z]", lines[i]):
subtag_depth += 1
if "[/" in lines[i]:
subtag_depth -= 1
Expand Down

0 comments on commit 4b81eb5

Please sign in to comment.