diff options
Diffstat (limited to 'module/plugins/hooks/EasybytezCom.py')
-rw-r--r-- | module/plugins/hooks/EasybytezCom.py | 28 |
1 files changed, 11 insertions, 17 deletions
diff --git a/module/plugins/hooks/EasybytezCom.py b/module/plugins/hooks/EasybytezCom.py index 1606c9f30..e08127514 100644 --- a/module/plugins/hooks/EasybytezCom.py +++ b/module/plugins/hooks/EasybytezCom.py @@ -8,10 +8,15 @@ from module.plugins.internal.MultiHook import MultiHook class EasybytezCom(MultiHook): __name__ = "EasybytezCom" __type__ = "hook" - __version__ = "0.06" + __version__ = "0.07" - __config__ = [("mode", "all;listed;unlisted", "Use for hosters (if supported)", "all"), - ("pluginlist", "str", "Hoster list (comma separated)", "")] + __config__ = [("pluginmode" , "all;listed;unlisted", "Use for plugins" , "all"), + ("pluginlist" , "str" , "Plugin list (comma separated)" , "" ), + ("revertfailed" , "bool" , "Revert to standard download if fails", True ), + ("retry" , "int" , "Number of retries before revert" , 10 ), + ("retryinterval" , "int" , "Retry interval in minutes" , 1 ), + ("reload" , "bool" , "Reload plugin list" , True ), + ("reloadinterval", "int" , "Reload interval in hours" , 12 )] __description__ = """EasyBytez.com hook plugin""" __license__ = "GPLv3" @@ -21,18 +26,7 @@ class EasybytezCom(MultiHook): def getHosters(self): user, data = self.account.selectAccount() - try: - req = self.account.getAccountRequest(user) - page = req.load("http://www.easybytez.com") + req = self.account.getAccountRequest(user) + page = req.load("http://www.easybytez.com") - hosters = re.search(r'</textarea>\s*Supported sites:(.*)', page).group(1).split(',') - - except Exception, e: - self.logWarning(_("Unable to load supported hoster list, using last known")) - self.logDebug(e) - - hosters = ["bitshare.com", "crocko.com", "ddlstorage.com", "depositfiles.com", "extabit.com", "hotfile.com", - "mediafire.com", "netload.in", "rapidgator.net", "rapidshare.com", "uploading.com", "uload.to", - "uploaded.to"] - finally: - return hosters + return re.search(r'</textarea>\s*Supported sites:(.*)', page).group(1).split(',') |