From 268509fb4982fbfb229d320747fab304cd0bc5ae Mon Sep 17 00:00:00 2001 From: rlaphoenix Date: Fri, 10 Feb 2023 19:26:46 +0000 Subject: [PATCH] Remove unused f-strings with no placeholders --- devine/commands/dl.py | 2 +- devine/core/utilities.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/devine/commands/dl.py b/devine/commands/dl.py index 9bc53da..7b80f41 100644 --- a/devine/commands/dl.py +++ b/devine/commands/dl.py @@ -183,7 +183,7 @@ class dl: if proxy: requested_provider = None - if re.match(rf"^[a-z]+:.+$", proxy, re.IGNORECASE): + if re.match(r"^[a-z]+:.+$", proxy, re.IGNORECASE): # requesting proxy from a specific proxy provider requested_provider, proxy = proxy.split(":", maxsplit=1) if re.match(r"^[a-z]{2}(?:\d+)?$", proxy, re.IGNORECASE): diff --git a/devine/core/utilities.py b/devine/core/utilities.py index b17a52f..e4939e1 100644 --- a/devine/core/utilities.py +++ b/devine/core/utilities.py @@ -74,7 +74,7 @@ def sanitize_filename(filename: str, spacer: str = ".") -> str: filename = filename.\ replace("/", " & ").\ replace(";", " & ") # e.g. multi-episode filenames - filename = re.sub(rf"[:; ]", spacer, filename) # structural chars to (spacer) + filename = re.sub(r"[:; ]", spacer, filename) # structural chars to (spacer) filename = re.sub(r"[\\*!?¿,'\"()<>|$#]", "", filename) # not filename safe chars filename = re.sub(rf"[{spacer}]{{2,}}", spacer, filename) # remove extra neighbouring (spacer)s