1
0
mirror of https://github.com/moparisthebest/SickRage synced 2024-12-12 11:02:21 -05:00

Code cleanup

This commit is contained in:
echel0n 2014-04-27 03:58:49 -07:00
parent cbc466138f
commit 6967a8faef
7 changed files with 19 additions and 19 deletions

View File

@ -47,9 +47,9 @@ class ImageCache:
def poster_path(self, indexer_id):
"""
Builds up the path to a poster cache for a given indexer id
Builds up the path to a poster cache for a given Indexer ID
returns: a full path to the cached poster file for the given indexer id
returns: a full path to the cached poster file for the given Indexer ID
indexer_id: ID of the show to use in the file name
"""
@ -58,9 +58,9 @@ class ImageCache:
def banner_path(self, indexer_id):
"""
Builds up the path to a banner cache for a given indexer id
Builds up the path to a banner cache for a given Indexer ID
returns: a full path to the cached banner file for the given indexer id
returns: a full path to the cached banner file for the given Indexer ID
indexer_id: ID of the show to use in the file name
"""
@ -69,9 +69,9 @@ class ImageCache:
def poster_thumb_path(self, indexer_id):
"""
Builds up the path to a poster cache for a given indexer id
Builds up the path to a poster cache for a given Indexer ID
returns: a full path to the cached poster file for the given indexer id
returns: a full path to the cached poster file for the given Indexer ID
indexer_id: ID of the show to use in the file name
"""
@ -80,9 +80,9 @@ class ImageCache:
def banner_thumb_path(self, indexer_id):
"""
Builds up the path to a poster cache for a given indexer id
Builds up the path to a poster cache for a given Indexer ID
returns: a full path to the cached poster file for the given indexer id
returns: a full path to the cached poster file for the given Indexer ID
indexer_id: ID of the show to use in the file name
"""
@ -91,7 +91,7 @@ class ImageCache:
def has_poster(self, indexer_id):
"""
Returns true if a cached poster exists for the given indexer id
Returns true if a cached poster exists for the given Indexer ID
"""
poster_path = self.poster_path(indexer_id)
logger.log(u"Checking if file " + str(poster_path) + " exists", logger.DEBUG)
@ -99,7 +99,7 @@ class ImageCache:
def has_banner(self, indexer_id):
"""
Returns true if a cached banner exists for the given indexer id
Returns true if a cached banner exists for the given Indexer ID
"""
banner_path = self.banner_path(indexer_id)
logger.log(u"Checking if file " + str(banner_path) + " exists", logger.DEBUG)
@ -107,7 +107,7 @@ class ImageCache:
def has_poster_thumbnail(self, indexer_id):
"""
Returns true if a cached poster thumbnail exists for the given indexer id
Returns true if a cached poster thumbnail exists for the given Indexer ID
"""
poster_thumb_path = self.poster_thumb_path(indexer_id)
logger.log(u"Checking if file " + str(poster_thumb_path) + " exists", logger.DEBUG)
@ -115,7 +115,7 @@ class ImageCache:
def has_banner_thumbnail(self, indexer_id):
"""
Returns true if a cached banner exists for the given indexer id
Returns true if a cached banner exists for the given Indexer ID
"""
banner_thumb_path = self.banner_thumb_path(indexer_id)
logger.log(u"Checking if file " + str(banner_thumb_path) + " exists", logger.DEBUG)

View File

@ -917,7 +917,7 @@ class GenericMetadata():
return empty_return
if indexer_id is None:
logger.log(u"Invalid indexer ID (" + str(indexer_id) + "), not using metadata file", logger.WARNING)
logger.log(u"Invalid Indexer ID (" + str(indexer_id) + "), not using metadata file", logger.WARNING)
return empty_return
except Exception, e:

View File

@ -509,7 +509,7 @@ class PostProcessor(object):
self._log(u"Checking scene exceptions for a match on " + cur_name, logger.DEBUG)
scene_id = scene_exceptions.get_scene_exception_by_name(cur_name)
if scene_id:
self._log(u"Scene exception lookup got a indexer id " + str(scene_id) + ", using that", logger.DEBUG)
self._log(u"Scene exception lookup got a Indexer ID " + str(scene_id) + ", using that", logger.DEBUG)
_finalize(parse_result)
return (scene_id, season, episodes)

View File

@ -57,7 +57,7 @@ def get_scene_exception_by_name(show_name):
if show_name.lower() in (
cur_exception_name.lower(), helpers.sanitizeSceneName(cur_exception_name).lower().replace('.', ' ')):
logger.log(u"Scene exception lookup got indexer id " + str(cur_indexer_id) + u", using that", logger.DEBUG)
logger.log(u"Scene exception lookup got Indexer ID " + str(cur_indexer_id) + u", using that", logger.DEBUG)
return cur_indexer_id
return None

View File

@ -237,7 +237,7 @@ class QueueItemAdd(ShowQueueItem):
ShowQueueItem.execute(self)
logger.log(u"Starting to add show " + self.showDir)
# make sure the indexer ids are valid
# make sure the Indexer IDs are valid
try:
lINDEXER_API_PARMS = sickbeard.indexerApi(self.indexer).api_params.copy()
@ -249,7 +249,7 @@ class QueueItemAdd(ShowQueueItem):
t = sickbeard.indexerApi(self.indexer).indexer(**lINDEXER_API_PARMS)
s = t[self.indexer_id]
# this usually only happens if they have an NFO in their show dir which gave us a indexer ID that has no proper english version of the show
# this usually only happens if they have an NFO in their show dir which gave us a Indexer ID that has no proper english version of the show
if getattr(s, 'seriesname', None) is None:
logger.log(u"Show in " + self.showDir + " has no name on " + sickbeard.indexerApi(
self.indexer).name + ", probably the wrong language used to search with.", logger.ERROR)

View File

@ -222,7 +222,7 @@ class TVCache():
if not indexer_id:
# check the name cache and see if we already know what show this is
logger.log(
u"Checking the cache to see if we already know the indexer id of " + parse_result.series_name,
u"Checking the cache to see if we already know the Indexer ID of " + parse_result.series_name,
logger.DEBUG)
indexer_id = name_cache.retrieveNameFromCache(parse_result.series_name)

View File

@ -2164,7 +2164,7 @@ class NewHomeAddShows:
# sanity check on our inputs
if (not rootDir and not fullShowPath) or not whichSeries:
return "Missing params, no indexer id or folder:" + repr(whichSeries) + " and " + repr(
return "Missing params, no Indexer ID or folder:" + repr(whichSeries) + " and " + repr(
rootDir) + "/" + repr(fullShowPath)
# figure out what show we're adding and where