mirror of
https://github.com/SickGear/SickGear.git
synced 2025-01-20 16:43:43 +00:00
Fix for No episode number found error for air-by-date/sports shows
This commit is contained in:
parent
ca4fe51b97
commit
0fddbac1c4
1 changed files with 6 additions and 4 deletions
|
@ -179,7 +179,6 @@ class NameParser(object):
|
|||
else:
|
||||
result.version = -1
|
||||
|
||||
|
||||
matches.append(result)
|
||||
|
||||
if len(matches):
|
||||
|
@ -218,6 +217,9 @@ class NameParser(object):
|
|||
"SELECT season, episode FROM tv_episodes WHERE showid = ? and indexer = ? and airdate = ?",
|
||||
[bestResult.show.indexerid, bestResult.show.indexer, airdate])
|
||||
|
||||
season_number = None
|
||||
episode_numbers = []
|
||||
|
||||
if sql_result:
|
||||
season_number = int(sql_result[0][0])
|
||||
episode_numbers = [int(sql_result[0][1])]
|
||||
|
@ -422,9 +424,9 @@ class NameParser(object):
|
|||
# anime absolute numbers
|
||||
final_result.ab_episode_numbers = self._combine_results(file_name_result, dir_name_result, 'ab_episode_numbers')
|
||||
|
||||
if not final_result.air_date:
|
||||
final_result.season_number = self._combine_results(file_name_result, dir_name_result, 'season_number')
|
||||
final_result.episode_numbers = self._combine_results(file_name_result, dir_name_result, 'episode_numbers')
|
||||
# season and episode numbers
|
||||
final_result.season_number = self._combine_results(file_name_result, dir_name_result, 'season_number')
|
||||
final_result.episode_numbers = self._combine_results(file_name_result, dir_name_result, 'episode_numbers')
|
||||
|
||||
# if the dirname has a release group/show name I believe it over the filename
|
||||
final_result.series_name = self._combine_results(dir_name_result, file_name_result, 'series_name')
|
||||
|
|
Loading…
Reference in a new issue