From 71c075a25b43220f793269c122b4fb17aa63f160 Mon Sep 17 00:00:00 2001 From: Manuel Mausz Date: Wed, 30 Sep 2015 21:53:04 +0200 Subject: Strip trailing slashes before case sensitive checking Strip trailing slashes. Otherwise the last pathname component might be empty --- module/plugins/internal/Plugin.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'module/plugins/internal/Plugin.py') diff --git a/module/plugins/internal/Plugin.py b/module/plugins/internal/Plugin.py index 6f3e52962..771966389 100644 --- a/module/plugins/internal/Plugin.py +++ b/module/plugins/internal/Plugin.py @@ -45,7 +45,7 @@ def encode(string, encoding='utf8'): def exists(path): if os.path.exists(path): if os.name == "nt": - dir, name = os.path.split(path) + dir, name = os.path.split(path.rstrip(os.sep)) return name in os.listdir(dir) else: return True -- cgit v1.2.3