summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar Stefano <l.stickell@yahoo.it> 2014-03-19 14:23:45 +0100
committerGravatar Stefano <l.stickell@yahoo.it> 2014-04-21 17:05:23 +0200
commit4a248d0d41dd7acf66d3c35155abea38383c00db (patch)
treee30d378600a3e147002a53ab7afdc5c0094c608e
parentZippyshare: fixed #542 (diff)
downloadpyload-4a248d0d41dd7acf66d3c35155abea38383c00db.tar.xz
Merge pull request #546 from CrazYoshi/patch-1
Easybytez registered user seen as premium account (cherry picked from commit d9b048ead90c26eae1d9a37c2fcd674b677a6495)
-rw-r--r--pyload/plugins/accounts/EasybytezCom.py10
1 files changed, 5 insertions, 5 deletions
diff --git a/pyload/plugins/accounts/EasybytezCom.py b/pyload/plugins/accounts/EasybytezCom.py
index 72f37b699..ffd132ba3 100644
--- a/pyload/plugins/accounts/EasybytezCom.py
+++ b/pyload/plugins/accounts/EasybytezCom.py
@@ -18,7 +18,7 @@
"""
import re
-from time import mktime, strptime
+from time import mktime, strptime, gmtime
from module.plugins.Account import Account
from module.plugins.internal.SimpleHoster import parseHtmlForm
@@ -27,7 +27,7 @@ from module.utils import parseFileSize
class EasybytezCom(Account):
__name__ = "EasybytezCom"
- __version__ = "0.03"
+ __version__ = "0.04"
__type__ = "account"
__description__ = """EasyBytez.com account plugin"""
__author_name__ = ("zoidberg")
@@ -44,19 +44,19 @@ class EasybytezCom(Account):
found = re.search(self.VALID_UNTIL_PATTERN, html)
if found:
- premium = True
- trafficleft = -1
try:
self.logDebug("Expire date: " + found.group(1))
validuntil = mktime(strptime(found.group(1), "%d %B %Y"))
except Exception, e:
self.logError(e)
+ if validuntil > mktime(gmtime()):
+ premium = True
+ trafficleft = -1
else:
found = re.search(self.TRAFFIC_LEFT_PATTERN, html)
if found:
trafficleft = found.group(1)
if "Unlimited" in trafficleft:
- premium = True
trafficleft = -1
else:
trafficleft = parseFileSize(trafficleft) / 1024