summaryrefslogtreecommitdiffstats
path: root/module/plugins/hooks/SimplyPremiumCom.py
diff options
context:
space:
mode:
authorGravatar Walter Purcaro <vuolter@gmail.com> 2014-12-27 21:20:59 +0100
committerGravatar Walter Purcaro <vuolter@gmail.com> 2014-12-27 21:20:59 +0100
commit575ce629081995766a231f0a9f3e97e3b79d23b1 (patch)
tree94066e87d5af5b9b1a11012eee11fcaf78bf8c68 /module/plugins/hooks/SimplyPremiumCom.py
parent[MultiHook] Crypter support (diff)
downloadpyload-575ce629081995766a231f0a9f3e97e3b79d23b1.tar.xz
Update MultiHook based hooks
Diffstat (limited to 'module/plugins/hooks/SimplyPremiumCom.py')
-rw-r--r--module/plugins/hooks/SimplyPremiumCom.py13
1 files changed, 6 insertions, 7 deletions
diff --git a/module/plugins/hooks/SimplyPremiumCom.py b/module/plugins/hooks/SimplyPremiumCom.py
index 10a1655c2..5f2d2a42c 100644
--- a/module/plugins/hooks/SimplyPremiumCom.py
+++ b/module/plugins/hooks/SimplyPremiumCom.py
@@ -1,19 +1,18 @@
# -*- coding: utf-8 -*-
from module.common.json_layer import json_loads
-from module.network.RequestFactory import getURL
from module.plugins.internal.MultiHook import MultiHook
class SimplyPremiumCom(MultiHook):
__name__ = "SimplyPremiumCom"
__type__ = "hook"
- __version__ = "0.03"
+ __version__ = "0.04"
__config__ = [("activated", "bool", "Activated", "False"),
- ("hosterListMode", "all;listed;unlisted", "Use for hosters (if supported)", "all"),
- ("hosterList", "str", "Hoster list (comma separated)", ""),
- ("unloadFailing", "bool", "Revert to standard download if download fails", "False"),
+ ("mode", "all;listed;unlisted", "Use for hosters (if supported)", "all"),
+ ("pluginlist", "str", "Hoster list (comma separated)", ""),
+ ("revertfailed", "bool", "Revert to standard download if download fails", "False"),
("interval", "int", "Reload interval in hours (0 to disable)", "24")]
__description__ = """Simply-Premium.com hook plugin"""
@@ -21,8 +20,8 @@ class SimplyPremiumCom(MultiHook):
__authors__ = [("EvolutionClip", "evolutionclip@live.de")]
- def getHoster(self):
- json_data = getURL("http://www.simply-premium.com/api/hosts.php", get={'format': "json", 'online': 1})
+ def getHosters(self):
+ json_data = self.getURL("http://www.simply-premium.com/api/hosts.php", get={'format': "json", 'online': 1})
json_data = json_loads(json_data)
host_list = [element['regex'] for element in json_data['result']]