From e260b201f94a2a1e470b85a6499ea70e20a11277 Mon Sep 17 00:00:00 2001 From: RaNaN Date: Fri, 26 Jun 2009 11:37:44 +0200 Subject: Cli stable, able to abort downloads, pause/kill server --- module/thread_list.py | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'module/thread_list.py') diff --git a/module/thread_list.py b/module/thread_list.py index 1dadb91d3..52b264648 100644 --- a/module/thread_list.py +++ b/module/thread_list.py @@ -99,18 +99,19 @@ class Thread_List(object): self.list.remove(pyfile) if pyfile.plugin.props['type'] == "container": - self.list.extend(pyfile.plugin.links) - - if pyfile.status.type == "reconnected":#put it back in queque + elif pyfile.status.type == "reconnected":#put it back in queque self.list.files.insert(0, pyfile) - if pyfile.status.type == "failed": + elif pyfile.status.type == "failed": self.parent.logger.warning("Download failed: " + pyfile.url+" | "+ pyfile.status.error) with open(self.parent.config['failed_file'], 'a') as f: f.write(pyfile.url + "\n") + self.list.remove(pyfile) + elif pyfile.status.type == "aborted": + self.parent.logger.info("Download aborted: " + pyfile.url) self.list.remove(pyfile) self.list.save() -- cgit v1.2.3