mirror of
https://github.com/moparisthebest/SickRage
synced 2024-12-04 15:12:23 -05:00
Fix for sickragetv/sickrage-issues#236
This commit is contained in:
parent
b667c722f2
commit
009da64975
@ -125,7 +125,9 @@ class GenericProvider:
|
||||
if not self._doLogin():
|
||||
return
|
||||
|
||||
self.headers.update({'Referer': self.proxy.getProxyURL()})
|
||||
if self.proxy.isEnabled():
|
||||
self.headers.update({'Referer': self.proxy.getProxyURL()})
|
||||
|
||||
return helpers.getURL(self.proxy._buildURL(url), post_data=post_data, params=params, headers=self.headers, timeout=timeout,
|
||||
session=self.session, json=json)
|
||||
|
||||
|
@ -38,10 +38,6 @@ from sickbeard import logger
|
||||
from sickbeard import tvcache
|
||||
from sickbeard.exceptions import ex, AuthException
|
||||
|
||||
from lib import requests
|
||||
from lib.requests import exceptions
|
||||
from lib.bencode import bdecode
|
||||
|
||||
class NewznabProvider(generic.NZBProvider):
|
||||
def __init__(self, name, url, key='', catIDs='5030,5040', search_mode='eponly', search_fallback=False,
|
||||
enable_daily=False, enable_backlog=False):
|
||||
@ -118,8 +114,6 @@ class NewznabProvider(generic.NZBProvider):
|
||||
return (False, return_categories, "Error getting html for [%s]" %
|
||||
("%s/api?%s" % (self.url, '&'.join("%s=%s" % (x,y) for x,y in params.items()) )))
|
||||
|
||||
#xml_categories = helpers.parse_xml(categories)
|
||||
|
||||
if not xml_categories:
|
||||
logger.log(u"Error parsing xml for [%s]" % (self.name),
|
||||
logger.DEBUG)
|
||||
|
@ -139,7 +139,8 @@ class TVCache():
|
||||
logger.log(traceback.format_exc(), logger.DEBUG)
|
||||
|
||||
def getRSSFeed(self, url, post_data=None, items=[]):
|
||||
self.provider.headers.update({'Referer': self.provider.proxy.getProxyURL()})
|
||||
if self.provider.proxy.isEnabled():
|
||||
self.provider.headers.update({'Referer': self.provider.proxy.getProxyURL()})
|
||||
return RSSFeeds(self.providerID).getFeed(self.provider.proxy._buildURL(url), post_data, self.provider.headers, items)
|
||||
|
||||
def _translateTitle(self, title):
|
||||
|
Loading…
Reference in New Issue
Block a user