diff options
Diffstat (limited to 'module/plugins/hoster/SmoozedCom.py')
-rw-r--r-- | module/plugins/hoster/SmoozedCom.py | 17 |
1 files changed, 7 insertions, 10 deletions
diff --git a/module/plugins/hoster/SmoozedCom.py b/module/plugins/hoster/SmoozedCom.py index bd653ff59..bf9f387b4 100644 --- a/module/plugins/hoster/SmoozedCom.py +++ b/module/plugins/hoster/SmoozedCom.py @@ -7,16 +7,21 @@ from module.plugins.internal.MultiHoster import MultiHoster class SmoozedCom(MultiHoster): __name__ = "SmoozedCom" __type__ = "hoster" - __version__ = "0.03" + __version__ = "0.07" __pattern__ = r'^unmatchable$' #: Since we want to allow the user to specify the list of hoster to use we let MultiHoster.coreReady + __config__ = [("use_premium", "bool", "Use premium account if available", True)] __description__ = """Smoozed.com hoster plugin""" __license__ = "GPLv3" __authors__ = [("", "")] - def handlePremium(self, pyfile): + FILE_ERRORS = [("Error", r'{"state":"error"}'), + ("Retry", r'{"state":"retry"}')] + + + def handleFree(self, pyfile): # In some cases hostsers do not supply us with a filename at download, so we # are going to set a fall back filename (e.g. for freakshare or xfileshare) pyfile.name = pyfile.name.split('/').pop() # Remove everthing before last slash @@ -53,11 +58,3 @@ class SmoozedCom(MultiHoster): self.fail(_("Unable to initialize download")) else: self.link = header["location"][-1] if isinstance(header["location"], list) else header["location"] - - - def checkFile(self): - if self.checkDownload({'error': '{"state":"error"}', - 'retry': '{"state":"retry"}'}): - self.fail(_("Error response received")) - - return super(SmoozedCom, self).checkFile() |