From 1de0443492774bee8cece103758a18af39f48efc Mon Sep 17 00:00:00 2001 From: Ruud Date: Tue, 24 Jun 2014 21:56:46 +0200 Subject: [PATCH] Get default "stop after" if it isn't set yet. fix #3499 --- couchpotato/core/plugins/quality/main.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/couchpotato/core/plugins/quality/main.py b/couchpotato/core/plugins/quality/main.py index 856cc22..27939a7 100644 --- a/couchpotato/core/plugins/quality/main.py +++ b/couchpotato/core/plugins/quality/main.py @@ -387,8 +387,8 @@ class QualityPlugin(Plugin): try: index = [i for i, identifier in enumerate(profile['qualities']) if identifier == quality['identifier'] and bool(profile['3d'][i] if profile.get('3d') else False) == bool(quality.get('is_3d', False))][0] - if index == 0 or profile['finish'][index] and int(release_age) >= int(profile['stop_after'][0]): - return True + if index == 0 or (profile['finish'][index] and int(release_age) >= int(profile.get('stop_after', [0])[0])): + return True return False except: