summaryrefslogtreecommitdiffstats
path: root/module/plugins/internal
diff options
context:
space:
mode:
authorGravatar Walter Purcaro <vuolter@gmail.com> 2014-10-18 13:46:19 +0200
committerGravatar Walter Purcaro <vuolter@gmail.com> 2014-10-18 13:46:19 +0200
commit6f47e10a9acf00eea4b47e5b364e75e78027809c (patch)
tree3137b126e11dcffcd3878de722c7932abbefac22 /module/plugins/internal
parentFix TRAFFIC_LEFT_PATTERN in RapidfileshareNet and TusfilesNet accounts (diff)
downloadpyload-6f47e10a9acf00eea4b47e5b364e75e78027809c.tar.xz
[XFSPCrypter] Better LINK_PATTERN
Diffstat (limited to 'module/plugins/internal')
-rw-r--r--module/plugins/internal/XFSPCrypter.py15
1 files changed, 2 insertions, 13 deletions
diff --git a/module/plugins/internal/XFSPCrypter.py b/module/plugins/internal/XFSPCrypter.py
index 4c5fff4f3..372657d2d 100644
--- a/module/plugins/internal/XFSPCrypter.py
+++ b/module/plugins/internal/XFSPCrypter.py
@@ -6,7 +6,7 @@ from module.plugins.internal.SimpleCrypter import SimpleCrypter
class XFSPCrypter(SimpleCrypter):
__name__ = "XFSPCrypter"
__type__ = "crypter"
- __version__ = "0.01"
+ __version__ = "0.02"
__pattern__ = None
@@ -21,19 +21,8 @@ class XFSPCrypter(SimpleCrypter):
COOKIES = [(HOSTER_NAME, "lang", "english")]
- LINK_PATTERN = None
+ LINK_PATTERN = r'<(?:td|TD) [^>]*>\s*<a href="(.+?)"[^>]*>.+?(?:</a>)?\s*</(?:td|TD)>'
TITLE_PATTERN = r'<[tT]itle>.*?\: (.+) folder</[tT]itle>'
OFFLINE_PATTERN = r'>\s*\w+ (Not Found|file (was|has been) removed)'
TEMP_OFFLINE_PATTERN = r'>\s*\w+ server (is in )?(maintenance|maintainance)'
-
-
- def prepare(self):
- if not self.HOSTER_NAME:
- self.fail("Missing HOSTER_NAME")
-
- if not self.LINK_PATTERN:
- pattern = r'<a href="(.+?)" target="_blank">.+?(?:</a>)?\s*</(?:td|TD)>'
- self.LINK_PATTERN = pattern % self.HOSTER_NAME
-
- super(XFSPCrypter, self).prepare()