mirror of https://github.com/morpheus65535/bazarr
Fix some horrible if statement
This commit is contained in:
parent
5c2651ba56
commit
5e5b09ed8c
|
@ -559,12 +559,12 @@ class SubtitleNameInfo(Resource):
|
|||
result = guessit(name, options=opts)
|
||||
|
||||
res = dict()
|
||||
if result['episode'] is not None:
|
||||
if 'episode' in result:
|
||||
res['episode'] = result['episode']
|
||||
else:
|
||||
res['episode'] = 0
|
||||
|
||||
if result['season'] is not None:
|
||||
if 'season' in result:
|
||||
res['season'] = result['season']
|
||||
else:
|
||||
res['season'] = 0
|
||||
|
|
Loading…
Reference in New Issue