diff options
author | Walter Purcaro <vuolter@users.noreply.github.com> | 2015-03-10 01:55:52 +0100 |
---|---|---|
committer | Walter Purcaro <vuolter@users.noreply.github.com> | 2015-03-10 01:55:52 +0100 |
commit | 7beb65e991bc6d1913c3b5bb2ef69e659d5b8342 (patch) | |
tree | e076082f6cb799a820eee287c47f24f082b3a41c /module/plugins/hooks/HotFolder.py | |
parent | [DDLMusicOrg] Removed (diff) | |
download | pyload-7beb65e991bc6d1913c3b5bb2ef69e659d5b8342.tar.xz |
Spare code cosmetics
Diffstat (limited to 'module/plugins/hooks/HotFolder.py')
-rw-r--r-- | module/plugins/hooks/HotFolder.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/module/plugins/hooks/HotFolder.py b/module/plugins/hooks/HotFolder.py index 302bc909f..a046e55e7 100644 --- a/module/plugins/hooks/HotFolder.py +++ b/module/plugins/hooks/HotFolder.py @@ -31,14 +31,14 @@ class HotFolder(Hook): def periodical(self): - folder = fs_encode(self.getConfig("folder")) - file = fs_encode(self.getConfig("file")) + folder = fs_encode(self.getConfig('folder')) + file = fs_encode(self.getConfig('file')) try: if not os.path.isdir(os.path.join(folder, "finished")): os.makedirs(os.path.join(folder, "finished")) - if self.getConfig("watch_file"): + if self.getConfig('watch_file'): with open(file, "a+") as f: f.seek(0) content = f.read().strip() @@ -60,7 +60,7 @@ class HotFolder(Hook): if not os.path.isfile(path) or f.endswith("~") or f.startswith("#") or f.startswith("."): continue - newpath = os.path.join(folder, "finished", f if self.getConfig("keep") else "tmp_" + f) + newpath = os.path.join(folder, "finished", f if self.getConfig('keep') else "tmp_" + f) move(path, newpath) self.logInfo(_("Added %s from HotFolder") % f) |