Later: Strip duplicate nicks given to @tell to avoid spam.

Suggested by @cottongin but implemented differently.
Closes GH-1261.
This commit is contained in:
Valentin Lorentz 2016-08-19 19:20:17 +02:00
parent 0f14c1c654
commit 1e7c3007e0

View File

@ -159,7 +159,7 @@ class Later(callbacks.Plugin):
""" """
self._deleteExpired() self._deleteExpired()
validnicks = [] validnicks = []
for nick in nicks: for nick in set(nicks): # Ignore duplicates
if ircutils.strEqual(nick, irc.nick): if ircutils.strEqual(nick, irc.nick):
irc.error(_('I can\'t send notes to myself.')) irc.error(_('I can\'t send notes to myself.'))
return return