From 6c9432165e2232e7a1346829da32116417758c66 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mike=20F=C3=A4hrmann?= Date: Mon, 24 Jul 2023 14:32:25 +0200 Subject: [PATCH] add return value to 'PostProcessor._init_archive()' --- gallery_dl/postprocessor/common.py | 2 ++ gallery_dl/postprocessor/python.py | 3 +-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/gallery_dl/postprocessor/common.py b/gallery_dl/postprocessor/common.py index c28d060d..10d9fbab 100644 --- a/gallery_dl/postprocessor/common.py +++ b/gallery_dl/postprocessor/common.py @@ -45,5 +45,7 @@ class PostProcessor(): self.name, archive, exc.__class__.__name__, exc) else: self.log.debug("Using %s archive '%s'", self.name, archive) + return True else: self.archive = None + return False diff --git a/gallery_dl/postprocessor/python.py b/gallery_dl/postprocessor/python.py index dd728108..db71da25 100644 --- a/gallery_dl/postprocessor/python.py +++ b/gallery_dl/postprocessor/python.py @@ -22,8 +22,7 @@ class PythonPP(PostProcessor): module = util.import_file(module_name) self.function = getattr(module, function_name) - self._init_archive(job, options) - if self.archive: + if self._init_archive(job, options): self.run = self.run_archive events = options.get("event")