summaryrefslogtreecommitdiffstats
path: root/module/plugins/internal/XFSCrypter.py
diff options
context:
space:
mode:
authorGravatar Walter Purcaro <vuolter@users.noreply.github.com> 2015-08-04 18:06:42 +0200
committerGravatar Walter Purcaro <vuolter@users.noreply.github.com> 2015-08-04 18:06:42 +0200
commit2cf928db10224b5327f918dceaa13273753620ac (patch)
tree2bf7d443308198f170c2b9eff137099467648059 /module/plugins/internal/XFSCrypter.py
parentMerge pull request #1696 from Gutz-Pilz/patch-4 (diff)
downloadpyload-2cf928db10224b5327f918dceaa13273753620ac.tar.xz
Some fixes
Diffstat (limited to 'module/plugins/internal/XFSCrypter.py')
-rw-r--r--module/plugins/internal/XFSCrypter.py9
1 files changed, 6 insertions, 3 deletions
diff --git a/module/plugins/internal/XFSCrypter.py b/module/plugins/internal/XFSCrypter.py
index fcb017466..eaf295bf2 100644
--- a/module/plugins/internal/XFSCrypter.py
+++ b/module/plugins/internal/XFSCrypter.py
@@ -6,7 +6,7 @@ from module.plugins.internal.SimpleCrypter import SimpleCrypter, create_getInfo
class XFSCrypter(SimpleCrypter):
__name__ = "XFSCrypter"
__type__ = "crypter"
- __version__ = "0.11"
+ __version__ = "0.12"
__status__ = "testing"
__pattern__ = r'^unmatchable$'
@@ -40,7 +40,10 @@ class XFSCrypter(SimpleCrypter):
else:
self.fail(_("Missing HOSTER_DOMAIN"))
- if isinstance(self.COOKIES, list):
- self.COOKIES.insert((self.HOSTER_DOMAIN, "lang", "english"))
+ if self.COOKIES:
+ if isinstance(self.COOKIES, list) and not self.COOKIES.count((self.HOSTER_DOMAIN, "lang", "english")):
+ self.COOKIES.insert((self.HOSTER_DOMAIN, "lang", "english"))
+ else:
+ set_cookie(self.req.cj, self.HOSTER_DOMAIN, "lang", "english")
return super(XFSCrypter, self).prepare()