summaryrefslogtreecommitdiffstats
path: root/module/plugins/hooks/PremiumizeMe.py
diff options
context:
space:
mode:
authorGravatar Sahil Shekhawat <sahilshekhawat01@gmail.com> 2015-01-05 19:31:35 +0100
committerGravatar Sahil Shekhawat <sahilshekhawat01@gmail.com> 2015-01-05 19:31:35 +0100
commit7b8593899e3d37846fb3ed94d47d9daba13a02d7 (patch)
tree5427650c3dd14b0c2878a1081be3709458bf48db /module/plugins/hooks/PremiumizeMe.py
parentCreated plugin for Nitroflare.com (diff)
parentSpare code improvements (diff)
downloadpyload-7b8593899e3d37846fb3ed94d47d9daba13a02d7.tar.xz
Merge branch 'stable' of https://github.com/pyload/pyload into stable
Diffstat (limited to 'module/plugins/hooks/PremiumizeMe.py')
-rw-r--r--module/plugins/hooks/PremiumizeMe.py20
1 files changed, 2 insertions, 18 deletions
diff --git a/module/plugins/hooks/PremiumizeMe.py b/module/plugins/hooks/PremiumizeMe.py
index c0717afc7..d334ddd25 100644
--- a/module/plugins/hooks/PremiumizeMe.py
+++ b/module/plugins/hooks/PremiumizeMe.py
@@ -7,7 +7,7 @@ from module.plugins.internal.MultiHook import MultiHook
class PremiumizeMe(MultiHook):
__name__ = "PremiumizeMe"
__type__ = "hook"
- __version__ = "0.15"
+ __version__ = "0.16"
__config__ = [("mode", "all;listed;unlisted", "Use for hosters (if supported):", "all"),
("pluginlist", "str", "Hoster list (comma separated)", ""),
@@ -20,12 +20,8 @@ class PremiumizeMe(MultiHook):
def getHosters(self):
- # If no accounts are available there will be no hosters available
- if not self.account or not self.account.canUse():
- return []
-
# Get account data
- (user, data) = self.account.selectAccount()
+ user, data = self.account.selectAccount()
# Get supported hosters list from premiumize.me using the
# json API v1 (see https://secure.premiumize.me/?show=api)
@@ -39,15 +35,3 @@ class PremiumizeMe(MultiHook):
# Extract hosters from json file
return data['result']['hosterlist']
-
-
- def coreReady(self):
- # Get account plugin and check if there is a valid account available
- self.account = self.core.accountManager.getAccountPlugin("PremiumizeMe")
- if not self.account.canUse():
- self.account = None
- self.logError(_("Please add a valid premiumize.me account first and restart pyLoad"))
- return
-
- # Run the overwriten core ready which actually enables the multihoster hook
- return MultiHook.coreReady(self)