From ecfeeb64458e2425420d145bae1da89bd6da9280 Mon Sep 17 00:00:00 2001 From: Walter Purcaro Date: Sun, 23 Nov 2014 17:29:06 +0100 Subject: [XFSAccount] Revert validuntil computation --- module/plugins/internal/XFSAccount.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/module/plugins/internal/XFSAccount.py b/module/plugins/internal/XFSAccount.py index 54ca5a8d8..f2a4e8a15 100644 --- a/module/plugins/internal/XFSAccount.py +++ b/module/plugins/internal/XFSAccount.py @@ -2,7 +2,7 @@ import re -from time import localtime, mktime, strptime +from time import gmtime, mktime, strptime from urlparse import urljoin from module.plugins.Account import Account @@ -12,7 +12,7 @@ from module.plugins.internal.SimpleHoster import parseHtmlForm, set_cookies class XFSAccount(Account): __name__ = "XFSAccount" __type__ = "account" - __version__ = "0.29" + __version__ = "0.30" __description__ = """XFileSharing account plugin""" __license__ = "GPLv3" @@ -67,7 +67,7 @@ class XFSAccount(Account): self.logDebug("Expire date: " + expiredate) try: - validuntil = mktime(strptime(expiredate, "%d %B %Y")) + 86400 + validuntil = mktime(strptime(expiredate, "%d %B %Y")) except Exception, e: self.logError(e) @@ -75,7 +75,7 @@ class XFSAccount(Account): else: self.logDebug("Valid until: %s" % validuntil) - if validuntil > mktime(localtime()): + if validuntil > mktime(gmtime()): premium = True trafficleft = -1 else: -- cgit v1.2.3