mirror of
https://github.com/SickGear/SickGear.git
synced 2024-12-01 00:43:37 +00:00
Fixed issue with new show searches not returning any data.
Fixed issue with show updater.
This commit is contained in:
parent
36fd50fb9c
commit
e19e0e8d1c
4 changed files with 15 additions and 11 deletions
|
@ -60,8 +60,12 @@ class GenericIndexer(object):
|
|||
'tr': 21, 'pl': 18, 'fr': 17, 'hr': 31, 'de': 14, 'da': 10, 'fi': 11,
|
||||
'hu': 19, 'ja': 25, 'he': 24, 'ko': 32, 'sv': 8, 'sl': 30}
|
||||
|
||||
self.base_url = INDEXER_BASEURL[indexer]
|
||||
self.api_parms = INDEXER_API_PARMS[indexer]
|
||||
self.indexerName = INDEXERS[indexer]
|
||||
self.cache = os.path.join(sickbeard.CACHE_DIR, indexer)
|
||||
self.indexers = [indexer for indexer in INDEXERS]
|
||||
self.indexers = [indexer for indexer in INDEXERS]
|
||||
|
||||
if indexer:
|
||||
self.base_url = INDEXER_BASEURL[indexer]
|
||||
self.api_parms = INDEXER_API_PARMS[indexer]
|
||||
self.name = INDEXERS[indexer]
|
||||
|
||||
if sickbeard.CACHE_DIR:
|
||||
self.cache = os.path.join(sickbeard.CACHE_DIR, indexer)
|
|
@ -28,7 +28,6 @@ from lib.tvrage_api.tvrage_api import TVRage
|
|||
class indexerApi(generic.GenericIndexer):
|
||||
def __init__(self, indexer=None, *args, **kwargs):
|
||||
super(indexerApi, self).__init__(indexer)
|
||||
self.name = self.indexerName
|
||||
|
||||
if indexer:
|
||||
self.api_parms.update(**kwargs)
|
||||
|
|
|
@ -40,8 +40,8 @@ class ShowUpdater():
|
|||
# update at 3 AM
|
||||
run_updater_time = datetime.time(hour=3)
|
||||
|
||||
update_datetime = datetime.time.today()
|
||||
update_date = update_datetime.date()
|
||||
update_datetime = datetime.time.now()
|
||||
update_date = update_datetime.time
|
||||
|
||||
logger.log(u"Checking update interval", logger.DEBUG)
|
||||
|
||||
|
|
|
@ -60,7 +60,8 @@ from sickbeard.scene_exceptions import get_scene_exceptions
|
|||
from sickbeard.scene_numbering import find_scene_numbering, set_scene_numbering, get_scene_numbering_for_show, get_xem_numbering_for_show
|
||||
from sickbeard.providers.generic import TorrentProvider
|
||||
|
||||
from sickbeard.indexers import indexer_api, indexer_exceptions
|
||||
from sickbeard.indexers.indexer_api import indexerApi
|
||||
from sickbeard.indexers.indexer_exceptions import indexer_shownotfound
|
||||
from lib.dateutil import tz
|
||||
from lib.unrar2 import RarFile, RarInfo
|
||||
|
||||
|
@ -1884,7 +1885,7 @@ class NewHomeAddShows:
|
|||
|
||||
@cherrypy.expose
|
||||
def getIndexerLanguages(self):
|
||||
result = indexer_api.indexerApi().config['valid_languages']
|
||||
result = indexerApi().config['valid_languages']
|
||||
|
||||
# Make sure list is sorted alphabetically but 'en' is in front
|
||||
if 'en' in result:
|
||||
|
@ -1978,7 +1979,7 @@ class NewHomeAddShows:
|
|||
logger.log(u"Unable to parse XML from " + indexer + " for some reason: " + ex(e), logger.ERROR)
|
||||
|
||||
|
||||
lang_id = indexer_api.indexerApi().config['langabbv_to_id'][lang]
|
||||
lang_id = indexerApi().config['langabbv_to_id'][lang]
|
||||
|
||||
return json.dumps({'results': results, 'langid': lang_id})
|
||||
|
||||
|
|
Loading…
Reference in a new issue