1
0
mirror of https://github.com/moparisthebest/SickRage synced 2024-12-13 11:32:20 -05:00

Disabled sceneConvert renamer for now till we add it in optionally.

This commit is contained in:
echel0n 2014-04-27 04:46:21 -07:00
parent 41293b1155
commit 831e9a537e

View File

@ -297,7 +297,7 @@ class TVShow(object):
# find all media files in the show folder and create episodes for as many as possible
def loadEpisodesFromDir(self):
def loadEpisodesFromDir(self, sceneConvert=False):
if not ek.ek(os.path.isdir, self._location):
logger.log(str(self.indexerid) + u": Show dir doesn't exist, not loading episodes from disk")
@ -310,17 +310,16 @@ class TVShow(object):
# create TVEpisodes from each media file (if possible)
for mediaFile in mediaFiles:
sceneConvert = False
parse_result = None
curEpisode = None
i = 0
if sceneConvert:
try:
i = 0
while i < 2:
i+=1
np = NameParser(False)
parse_result = np.parse(mediaFile, sceneConvert)
parse_result = np.parse(mediaFile, True if i > 1 else False)
if helpers.validateShow(self, parse_result.season_number, parse_result.episode_numbers[0]):
ep = TVEpisode(self, parse_result.season_number, parse_result.episode_numbers[0])
proper_path = ep.proper_path()
@ -350,7 +349,6 @@ class TVShow(object):
# converted
break
sceneConvert = True
except Exception:
continue
@ -371,6 +369,7 @@ class TVShow(object):
ep_file_name = ek.ek(os.path.splitext, ep_file_name)[0]
try:
parse_result = None
np = NameParser(False)
parse_result = np.parse(ep_file_name)
except InvalidNameException: