permit spaces before ++/-- for single-word karma

This commit is contained in:
jesopo 2019-12-19 15:06:15 +00:00
parent 598a41da8c
commit 5ff5b07c22

View file

@ -7,7 +7,7 @@ from src import EventManager, ModuleManager, utils
KARMA_DELAY_SECONDS = 3 KARMA_DELAY_SECONDS = 3
REGEX_WORD = re.compile(r"^([^(\s,:]+)(?:[:,]\s*)?(\+\+|--)\s*$") REGEX_WORD = re.compile(r"^([^(\s,:]+)(?:[:,])?\s*(\+\+|--)\s*$")
REGEX_WORD_START = re.compile(r"^(\+\+|--)(?:\s*)([^(\s,:]+)\s*$") REGEX_WORD_START = re.compile(r"^(\+\+|--)(?:\s*)([^(\s,:]+)\s*$")
REGEX_PARENS = re.compile(r"\(([^)]+)\)(\+\+|--)") REGEX_PARENS = re.compile(r"\(([^)]+)\)(\+\+|--)")