Skip to content

Commit

Permalink
Fix scene exceptions with year not being used (#8518)
Browse files Browse the repository at this point in the history
* Fix scene exceptions with year not being used

* rm unused import
  • Loading branch information
medariox authored Sep 22, 2020
1 parent 830c7a0 commit 8f90292
Showing 1 changed file with 2 additions and 8 deletions.
10 changes: 2 additions & 8 deletions medusa/name_parser/guessit_parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,6 @@
from datetime import timedelta
from time import time

from guessit.rules.common.date import valid_year

from medusa import app
from medusa.name_parser.rules import default_api

Expand Down Expand Up @@ -105,13 +103,9 @@ def get_expected_titles(show_list):
if not match:
continue

series, year, _ = match.groups()
if year and not valid_year(int(year)):
series = exception

if not any(char.isdigit() or char == '-' for char in series):
if not any(char.isdigit() or char == '-' for char in exception):
continue

expected_titles.append(series)
expected_titles.append(exception)

return expected_titles

0 comments on commit 8f90292

Please sign in to comment.