Fix an error in re.sub() call.