diff options
author | Stefano <l.stickell@yahoo.it> | 2013-05-14 12:13:31 +0200 |
---|---|---|
committer | Stefano <l.stickell@yahoo.it> | 2013-05-14 12:13:31 +0200 |
commit | e1f79ddb61fb454494b3c8fd7c97df3be0387770 (patch) | |
tree | c226417662302fdb99b92285fc8c74941e2a949b /module/plugins/accounts | |
parent | Merge pull request #115 from 4Christopher/Movie2kTo (diff) | |
download | pyload-e1f79ddb61fb454494b3c8fd7c97df3be0387770.tar.xz |
FilefactoryCom: fixed validuntil parser
Diffstat (limited to 'module/plugins/accounts')
-rw-r--r-- | module/plugins/accounts/FilefactoryCom.py | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/module/plugins/accounts/FilefactoryCom.py b/module/plugins/accounts/FilefactoryCom.py index 356c5d22a..8e163e2f6 100644 --- a/module/plugins/accounts/FilefactoryCom.py +++ b/module/plugins/accounts/FilefactoryCom.py @@ -23,13 +23,13 @@ from time import mktime, strptime class FilefactoryCom(Account): __name__ = "FilefactoryCom" - __version__ = "0.12" + __version__ = "0.13" __type__ = "account" __description__ = """filefactory.com account plugin""" - __author_name__ = ("zoidberg") - __author_mail__ = ("zoidberg@mujmail.cz") + __author_name__ = ("zoidberg", "stickell") + __author_mail__ = ("zoidberg@mujmail.cz", "l.stickell@yahoo.it") - ACCOUNT_INFO_PATTERN = r'<a href="/premium/">.*?datetime="(.*?)"' + ACCOUNT_INFO_PATTERN = r'<time datetime="([\d-]+)">' def loadAccountInfo(self, user, req): html = req.load("http://www.filefactory.com/member/") @@ -37,7 +37,7 @@ class FilefactoryCom(Account): found = re.search(self.ACCOUNT_INFO_PATTERN, html) if found: premium = True - validuntil = mktime(strptime(re.sub(r"(\d)[a-z]{2} ", r"\1 ", found.group(1)),"%d %B, %Y")) + validuntil = mktime(strptime(found.group(1),"%Y-%m-%d")) else: premium = False validuntil = -1 |