Skip to content

Commit

Permalink
Fix provider torrenday. (#9628)
Browse files Browse the repository at this point in the history
* Fix provider torrenday.
* Needed new cookie cf_clearance.

* update changelog
  • Loading branch information
p0psicles authored Jun 12, 2021
1 parent b221f6b commit 4ae5326
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 3 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
#### Fixes
- Add support for new synology download station api. Credits to Benjv. ([9555](https://github.com/pymedusa/Medusa/pull/9555))
- Fix shows not being removed from UI. ([9563](https://github.com/pymedusa/Medusa/pull/9563))
- Fix provider torrentday. Needs additional cookie cf_clearance. ([9628](https://github.com/pymedusa/Medusa/pull/9628))

-----

Expand Down
4 changes: 2 additions & 2 deletions medusa/providers/generic_provider.py
Original file line number Diff line number Diff line change
Expand Up @@ -791,8 +791,8 @@ def add_cookies_from_ui(self):
return {'result': False,
'message': 'No Cookies added from ui for provider: {0}'.format(self.name)}

cookie_validator = re.compile(r'^([\w%]+=[\w%]+)(;[\w%]+=[\w%]+)*$')
if not cookie_validator.match(self.cookies):
cookie_validator = re.compile(r'([\w%]+=[\w%]+)')
if not cookie_validator.findall(self.cookies):
ui.notifications.message(
'Failed to validate cookie for provider {provider}'.format(provider=self.name),
'Cookie is not correctly formatted: {0}'.format(self.cookies))
Expand Down
2 changes: 1 addition & 1 deletion medusa/providers/torrent/json/torrentday.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ def __init__(self):
self.freeleech = False
self.enable_cookies = True
self.cookies = ''
self.required_cookies = ('uid', 'pass')
self.required_cookies = ('uid', 'pass', 'cf_clearance')

# TV/480p - 24
# TV/Bluray - 32
Expand Down

0 comments on commit 4ae5326

Please sign in to comment.