decouple extractor initialization
Introduce an 'initialize()' function that does the actual init (session, cookies, config options) and can called separately from the constructor __init__(). This allows, for example, to adjust config access inside a Job before most of it already happened when calling 'extractor.find()'.
This commit is contained in:
@@ -57,8 +57,10 @@ class ReadcomiconlineIssueExtractor(ReadcomiconlineBase, ChapterExtractor):
|
||||
|
||||
def __init__(self, match):
|
||||
ChapterExtractor.__init__(self, match)
|
||||
self.params = match.group(2)
|
||||
|
||||
params = text.parse_query(match.group(2))
|
||||
def _init(self):
|
||||
params = text.parse_query(self.params)
|
||||
quality = self.config("quality")
|
||||
|
||||
if quality is None or quality == "auto":
|
||||
|
||||
Reference in New Issue
Block a user