diff options
author | Jon Bergli Heier <snakebite@jvnv.net> | 2012-03-22 19:18:42 +0100 |
---|---|---|
committer | Jon Bergli Heier <snakebite@jvnv.net> | 2012-03-22 19:18:42 +0100 |
commit | 9106db6e2791eb974aadf5382be2257691990c47 (patch) | |
tree | 98636ed56b717509d950fcf4baf5b0ea529762f2 | |
parent | c353232128bb862f6222be7774fd32a6f4d591be (diff) |
imdb_search: Fixed error when rating is missing.
-rw-r--r-- | modules/imdb_search.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/modules/imdb_search.py b/modules/imdb_search.py index 0031093..34ba6cc 100644 --- a/modules/imdb_search.py +++ b/modules/imdb_search.py @@ -22,7 +22,7 @@ class Module: if len(results): m = results[0] self.ia.update(m) - s = u'\002%s\002 (%d) %.1f/10 | %s' % (m['title'], m['year'], m['rating'], self.ia.get_imdbURL(m)) + s = u'\002%s\002 (%d) %s/10 | %s' % (m['title'], m['year'], ('%.1f' % m['rating']) if 'rating' in m else '?', self.ia.get_imdbURL(m)) self.irc.msg(target, s.encode('utf-8')) else: self.irc.msg(target, 'imdb: No results.') |