mirror of
https://github.com/SickGear/SickGear.git
synced 2024-12-03 18:03:37 +00:00
Forgot to add check if naming pattern was calling nameparser for previous commit.
This commit is contained in:
parent
c3f6417f5f
commit
2fec443c37
1 changed files with 15 additions and 14 deletions
|
@ -236,22 +236,23 @@ class NameParser(object):
|
||||||
# scene convert result
|
# scene convert result
|
||||||
bestResult = bestResult.convert() if self.convert and not self.naming_pattern else bestResult
|
bestResult = bestResult.convert() if self.convert and not self.naming_pattern else bestResult
|
||||||
|
|
||||||
if bestResult.show and bestResult.show.is_anime and len(bestResult.ab_episode_numbers):
|
if not self.naming_pattern:
|
||||||
new_episode_numbers = []
|
if bestResult.show and bestResult.show.is_anime and len(bestResult.ab_episode_numbers):
|
||||||
new_season_numbers = []
|
new_episode_numbers = []
|
||||||
|
new_season_numbers = []
|
||||||
|
|
||||||
for epAbsNo in bestResult.ab_episode_numbers:
|
for epAbsNo in bestResult.ab_episode_numbers:
|
||||||
try:
|
try:
|
||||||
(s, e) = helpers.get_all_episodes_from_absolute_number(bestResult.show, None, [epAbsNo])
|
(s, e) = helpers.get_all_episodes_from_absolute_number(bestResult.show, None, [epAbsNo])
|
||||||
except exceptions.EpisodeNotFoundByAbsoluteNumberException:
|
except exceptions.EpisodeNotFoundByAbsoluteNumberException:
|
||||||
pass
|
pass
|
||||||
else:
|
else:
|
||||||
new_episode_numbers.extend(e)
|
new_episode_numbers.extend(e)
|
||||||
new_season_numbers.append(s)
|
new_season_numbers.append(s)
|
||||||
|
|
||||||
if len(new_season_numbers) and len(new_episode_numbers):
|
if len(new_season_numbers) and len(new_episode_numbers):
|
||||||
bestResult.episode_numbers = new_episode_numbers
|
bestResult.episode_numbers = new_episode_numbers
|
||||||
bestResult.season_number = new_season_numbers[0]
|
bestResult.season_number = new_season_numbers[0]
|
||||||
|
|
||||||
return bestResult
|
return bestResult
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue