Fixed a bug in imdb
This commit is contained in:
parent
afc556281e
commit
2bdb7a7915
1 changed files with 1 additions and 1 deletions
|
@ -17,7 +17,7 @@ def imdb(inp):
|
||||||
else:
|
else:
|
||||||
content = http.get_json("http://www.omdbapi.com/", t=strip)
|
content = http.get_json("http://www.omdbapi.com/", t=strip)
|
||||||
|
|
||||||
if content['Error'] == 'Movie not found!':
|
if content.get('Error', None) == 'Movie not found!':
|
||||||
return 'Movie not found!'
|
return 'Movie not found!'
|
||||||
elif content['Response'] == 'True':
|
elif content['Response'] == 'True':
|
||||||
content['URL'] = 'http://www.imdb.com/title/%(imdbID)s' % content
|
content['URL'] = 'http://www.imdb.com/title/%(imdbID)s' % content
|
||||||
|
|
Reference in a new issue