Provide a proper response for Later.notes when no notes are waiting.

This commit is contained in:
James Vega 2005-02-07 17:26:42 +00:00
parent 70d1b1d5d0
commit de7d0fae74

View File

@ -130,8 +130,12 @@ class Later(callbacks.Privmsg):
irc.error('I have no notes for that nick.')
else:
nicks = self._notes.keys()
utils.sortBy(ircutils.toLower, nicks)
irc.reply(format('I currently have notes waiting for %L.', nicks))
if nicks:
utils.sortBy(ircutils.toLower, nicks)
irc.reply(format('I currently have notes waiting for %L.',
nicks))
else:
irc.error('I have no notes waiting to be delivered.')
notes = wrap(notes, [additional('something')])
def doPrivmsg(self, irc, msg):