summaryrefslogtreecommitdiffstats
path: root/module/thread_list.py
diff options
context:
space:
mode:
authorGravatar mkaay <mkaay@mkaay.de> 2009-12-04 20:01:17 +0100
committerGravatar mkaay <mkaay@mkaay.de> 2009-12-04 20:01:17 +0100
commit78f061eed59e084f001f8a0cd9c5b585f6fc0ce0 (patch)
tree1c5cc3cbfa4eb993a5af0f2b6556e1ff5f0021c7 /module/thread_list.py
parentConvert read_url_list to new Plugin (diff)
downloadpyload-78f061eed59e084f001f8a0cd9c5b585f6fc0ce0.tar.xz
fixes, minimal gui changes
Diffstat (limited to 'module/thread_list.py')
-rw-r--r--module/thread_list.py16
1 files changed, 9 insertions, 7 deletions
diff --git a/module/thread_list.py b/module/thread_list.py
index 55f237544..3c69121c2 100644
--- a/module/thread_list.py
+++ b/module/thread_list.py
@@ -107,14 +107,16 @@ class Thread_List(object):
if pyfile.status.type == "finished":
if pyfile.plugin.props['type'] == "container":
#works(!) but adds many packs to queue
+ self.list.packager.removeFileFromPackage(pyfile.id, pyfile.package.data["id"])
newLinks = 0
- newPackager = self.list.packager.addNewPackage(pyfile.status.filename)
- for link in pyfile.plugin.links:
- newFile = self.list.collector.addLink(link)
- self.list.packager.addFileToPackage(newPackager, self.list.collector.popFile(newFile))
- newLinks += 1
- self.list.packager.pushPackage2Queue(newPackager)
-
+ if pyfile.plugin.links:
+ newPackager = self.list.packager.addNewPackage(pyfile.status.filename)
+ for link in pyfile.plugin.links:
+ newFile = self.list.collector.addLink(link)
+ self.list.packager.addFileToPackage(newPackager, self.list.collector.popFile(newFile))
+ newLinks += 1
+ self.list.packager.pushPackage2Queue(newPackager)
+
if newLinks:
self.parent.logger.info("Parsed link from %s: %i" % (pyfile.status.filename, newLinks))
else: