From 30655b2af070a595756a89f2314c181db8b8b77d Mon Sep 17 00:00:00 2001 From: Jylpah Date: Sun, 4 Nov 2018 16:46:27 +0200 Subject: [PATCH] Fixed weird bug with direcotory names ending dir separator --- wotbreplay_uploader.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/wotbreplay_uploader.py b/wotbreplay_uploader.py index 2dd7080..3fc3cdb 100644 --- a/wotbreplay_uploader.py +++ b/wotbreplay_uploader.py @@ -100,6 +100,8 @@ async def mkReplayQ(queue : asyncio.Queue, files : list, title : str): await queue.put(await mkQueueItem(line, title)) else: for fn in files: + if fn.endswith(os.sep): + fn = fn[:-1] if os.path.isfile(fn) and (p_replayfile.match(fn) != None): await queue.put(await mkQueueItem(fn, title)) elif os.path.isdir(fn):