fix minor bugs in suggest.py and seen.py
This commit is contained in:
parent
9f0addbca7
commit
808d049c4e
|
@ -54,7 +54,7 @@ def seen(bot, input):
|
|||
|
||||
if(results != None):
|
||||
reltime = timesince.timesince(datetime.fromtimestamp(results[0]))
|
||||
return '%s was last seen %s ago saying: <%s> %s' % \
|
||||
return '%s was last seen %s ago saying: %s' % \
|
||||
(query, reltime, results[1])
|
||||
else:
|
||||
return "I've never seen %s" % query
|
||||
|
|
|
@ -16,5 +16,5 @@ def suggest(inp):
|
|||
suggestions = yaml.load(json)[1]
|
||||
if not suggestions:
|
||||
return 'no suggestions found'
|
||||
suggestion = random.choice(suggestions)
|
||||
return '#%d: %s (%s)' % tuple([int(suggestion[2]) + 1] + suggestion[0:2])
|
||||
out = random.choice(suggestions)
|
||||
return '#%d: %s (%s)' % (int(out[2][0]) + 1, out[0], out[1])
|
||||
|
|
Loading…
Reference in New Issue