fix imdb
This commit is contained in:
parent
8650c8dd39
commit
f42b8ec280
|
@ -12,13 +12,13 @@ def imdb(inp):
|
||||||
if content['Response'] == 'Movie Not Found':
|
if content['Response'] == '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/%(ID)s' % content
|
content['URL'] = 'http://www.imdb.com/title/%(imdbID)s' % content
|
||||||
|
|
||||||
out = '\x02%(Title)s\x02 (%(Year)s) (%(Genre)s): %(Plot)s'
|
out = '\x02%(Title)s\x02 (%(Year)s) (%(Genre)s): %(Plot)s'
|
||||||
if content['Runtime'] != 'N/A':
|
if content['Runtime'] != 'N/A':
|
||||||
out += ' \x02%(Runtime)s\x02.'
|
out += ' \x02%(Runtime)s\x02.'
|
||||||
if content['Rating'] != 'N/A' and content['Votes'] != 'N/A':
|
if content['imdbRating'] != 'N/A' and content['imdbVotes'] != 'N/A':
|
||||||
out += ' \x02%(Rating)s/10\x02 with \x02%(Votes)s\x02 votes.'
|
out += ' \x02%(imdbRating)s/10\x02 with \x02%(imdbVotes)s\x02 votes.'
|
||||||
out += ' %(URL)s'
|
out += ' %(URL)s'
|
||||||
return out % content
|
return out % content
|
||||||
else:
|
else:
|
||||||
|
|
Loading…
Reference in New Issue