mirror of
https://github.com/SickGear/SickGear.git
synced 2025-01-20 16:43:43 +00:00
Fix for scene numbering during post-processing
This commit is contained in:
parent
c2e79bf031
commit
dfd6f38cfe
2 changed files with 10 additions and 5 deletions
|
@ -626,7 +626,7 @@ class PostProcessor(object):
|
|||
# now that we've figured out which episode this file is just load it manually
|
||||
try:
|
||||
# convert scene numbered release and load episode from database
|
||||
curEp = show_obj.getEpisode(scene_season=season, scene_episode=cur_episode)
|
||||
curEp = show_obj.getEpisode(season, cur_episode, scene=True)
|
||||
except exceptions.EpisodeNotFoundException, e:
|
||||
self._log(u"Unable to create episode: " + ex(e), logger.DEBUG)
|
||||
raise exceptions.PostProcessingFailed()
|
||||
|
|
|
@ -182,7 +182,7 @@ class TVShow(object):
|
|||
return ep_list
|
||||
|
||||
|
||||
def getEpisode(self, season, episode, file=None, noCreate=False):
|
||||
def getEpisode(self, season, episode, file=None, noCreate=False, scene=False):
|
||||
|
||||
if not season in self.episodes:
|
||||
self.episodes[season] = {}
|
||||
|
@ -197,10 +197,15 @@ class TVShow(object):
|
|||
episode) + " didn't exist in the cache, trying to create it", logger.DEBUG)
|
||||
|
||||
if file != None:
|
||||
ep = TVEpisode(self, season, episode, file)
|
||||
if scene:
|
||||
ep = TVEpisode(self, scene_season=season, scene_episode=episode, file=file)
|
||||
else:
|
||||
ep = TVEpisode(self, season, episode, file)
|
||||
else:
|
||||
ep = TVEpisode(self, season, episode)
|
||||
|
||||
if scene:
|
||||
ep = TVEpisode(self, scene_season=season, scene_episode=episode)
|
||||
else:
|
||||
ep = TVEpisode(self, season, episode, file)
|
||||
if ep != None:
|
||||
self.episodes[season][episode] = ep
|
||||
|
||||
|
|
Loading…
Reference in a new issue