seds starting with numbers caused an "invalid group reference"
This commit is contained in:
parent
2c524303aa
commit
dff1a8fb7f
1 changed files with 6 additions and 1 deletions
|
@ -73,7 +73,12 @@ class Module(ModuleManager.BaseModule):
|
|||
if match:
|
||||
replace = sed_split[2]
|
||||
replace = replace.replace("\\/", "/")
|
||||
replace = re.sub(SED_AMPERSAND, "\\1%s" % match, replace)
|
||||
|
||||
with utils.deadline():
|
||||
for found in SED_AMPERSAND.finditer(replace):
|
||||
found = found.group(1)
|
||||
replace.replace(found, "%s%s" % (found, match))
|
||||
|
||||
replace_color = utils.irc.bold(replace)
|
||||
|
||||
new_message = re.sub(pattern, replace, message, count)
|
||||
|
|
Loading…
Reference in a new issue