From 50d504a38f57684e366128dd1b214f65db476bf9 Mon Sep 17 00:00:00 2001 From: TannerMoore Date: Fri, 29 Apr 2016 23:23:18 +0100 Subject: [PATCH] [AutoAdd] Fix watch dir not accepting uppercase file extension - Auto-add feature will now accept torrents when the .torrent extension has capital letters in it --- deluge/plugins/AutoAdd/deluge/plugins/autoadd/core.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/deluge/plugins/AutoAdd/deluge/plugins/autoadd/core.py b/deluge/plugins/AutoAdd/deluge/plugins/autoadd/core.py index 81a4b08d2..ae74b02f6 100644 --- a/deluge/plugins/AutoAdd/deluge/plugins/autoadd/core.py +++ b/deluge/plugins/AutoAdd/deluge/plugins/autoadd/core.py @@ -252,12 +252,13 @@ class Core(CorePluginBase): # Skip directories continue else: - ext = os.path.splitext(filename)[1] + ext = os.path.splitext(filename)[1].lower() if ext == ".torrent": magnet = False elif ext == ".magnet": magnet = True else: + log.debug("File checked for auto-loading is invalid: %s", filename) continue try: filedump = self.load_torrent(filepath, magnet)