From 7c2d86375ecabccaeb2119ff60ae7f9a838a2479 Mon Sep 17 00:00:00 2001 From: Johan Andersson Date: Fri, 5 Oct 2018 23:25:52 +0200 Subject: [PATCH] utils.output: dot and dash is optional --- lib/svtplay_dl/utils/output.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/svtplay_dl/utils/output.py b/lib/svtplay_dl/utils/output.py index 505bf65..917c6cd 100644 --- a/lib/svtplay_dl/utils/output.py +++ b/lib/svtplay_dl/utils/output.py @@ -175,7 +175,7 @@ def _formatname(output, config, extension): name = name.replace("{ext}", output[key]) # Remove all {text} we cant replace with something - for item in re.findall("([\.\-](([^\.\-]+\w+)?\{[\w\-]+\}))", name): + for item in re.findall("([\.\-]?(([^\.\-]+\w+)?\{[\w\-]+\}))", name): if "season" in output and output["season"] and re.search("(e\{[\w\-]+\})", name): name = name.replace(re.search("(e\{[\w\-]+\})", name).group(1), "") else: