Cosmetics, replace safe filename regex with triple-quoted string so we don't have to bḁash-escape literal double quote
This commit is contained in:
parent
c5f74ce479
commit
7b391be89e
@ -359,7 +359,7 @@ def get_safe_filename(
|
|||||||
dirty_filename: str) -> str:
|
dirty_filename: str) -> str:
|
||||||
"""https://stackoverflow.com/a/71199182"""
|
"""https://stackoverflow.com/a/71199182"""
|
||||||
|
|
||||||
clean_filename = re.sub(r"[/\\?%*:|\"<>\x7F\x00-\x1F]", "-", dirty_filename)
|
clean_filename = re.sub(r"""[/\\?%*:|"<>\x7F\x00-\x1F]""", "-", dirty_filename)
|
||||||
return clean_filename
|
return clean_filename
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user