start factoid rankings from 1 not from 0

This commit is contained in:
Daniel Folkinshteyn 2010-03-15 23:12:35 -04:00
parent 3326212d55
commit 0e50249256

View File

@ -255,7 +255,7 @@ class Factoids(callbacks.Plugin, plugins.ChannelDBHandler):
ORDER BY factoids.usage_count DESC
LIMIT %s""", numfacts)
factkeys = cursor.fetchall()
s = [ "#%d %s (%d)" % (i, key[0], key[1]) for i, key in enumerate(factkeys) ]
s = [ "#%d %s (%d)" % (i+1, key[0], key[1]) for i, key in enumerate(factkeys) ]
irc.reply(", ".join(s))
factrank = wrap(factrank, ['channel'])