From 688263bd62063250a7f8dd3b88a4571961ff06e7 Mon Sep 17 00:00:00 2001 From: echel0n Date: Sun, 22 Jun 2014 12:58:26 -0700 Subject: [PATCH] Fix for missing code in Name Parser --- sickbeard/name_parser/parser.py | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/sickbeard/name_parser/parser.py b/sickbeard/name_parser/parser.py index b4dffeab..2f805120 100644 --- a/sickbeard/name_parser/parser.py +++ b/sickbeard/name_parser/parser.py @@ -230,12 +230,14 @@ class NameParser(object): result.release_group = match.group('release_group') result.score += 1 - if getattr(self.showObj, 'air_by_date', None) and result.air_date: - result.score += 1 - elif getattr(self.showObj, 'sports', None) and result.sports_event_date: - result.score += 1 - elif getattr(self.showObj, 'anime', None) and len(result.ab_episode_numbers): - result.score += 1 + if self.showObj: + result.show = self.showObj + if getattr(self.showObj, 'air_by_date', None) and result.air_date: + result.score += 1 + elif getattr(self.showObj, 'sports', None) and result.sports_event_date: + result.score += 1 + elif getattr(self.showObj, 'anime', None) and len(result.ab_episode_numbers): + result.score += 1 result.score += 1 matches.append(result)