1
0
mirror of https://github.com/mail-in-a-box/mailinabox.git synced 2025-06-26 22:00:54 +00:00

Fixed RUF055 (unnecessary-regular-expression): Plain string pattern passed to re function

This commit is contained in:
Teal Dulcet 2025-06-18 04:32:38 -07:00
parent ed1579a5c6
commit 529c7e6dd5

View File

@ -408,7 +408,7 @@ class BashScript(Grammar):
string = re.sub(".* #NODOC\n", "", string) string = re.sub(".* #NODOC\n", "", string)
string = re.sub("\n\\s*if .*then.*|\n\\s*fi|\n\\s*else|\n\\s*elif .*", "", string) string = re.sub("\n\\s*if .*then.*|\n\\s*fi|\n\\s*else|\n\\s*elif .*", "", string)
string = quasitokenize(string) string = quasitokenize(string)
string = re.sub(r"hide_output ", "", string) string = string.replace(r"hide_output ", "")
parser = BashScript.parser() parser = BashScript.parser()
result = parser.parse_string(string) result = parser.parse_string(string)