mirror of
https://github.com/Mikaela/Limnoria.git
synced 2024-11-02 17:29:22 +01:00
Better error messages in addAlias.
This commit is contained in:
parent
4cb7c18392
commit
5c1ecc2248
@ -200,9 +200,9 @@ class Alias(callbacks.Privmsg):
|
|||||||
name = realName
|
name = realName
|
||||||
cb = callbacks.findCallbackForCommand(irc, name)
|
cb = callbacks.findCallbackForCommand(irc, name)
|
||||||
if cb is not None and cb != self:
|
if cb is not None and cb != self:
|
||||||
raise AliasError, 'A command with that name already exists.'
|
raise AliasError, 'A command with the name %r already exists.'%name
|
||||||
if name in self.frozen:
|
if name in self.frozen:
|
||||||
raise AliasError, 'That alias is frozen.'
|
raise AliasError, 'Alias %r is frozen.' % name
|
||||||
try:
|
try:
|
||||||
f = makeNewAlias(name, alias)
|
f = makeNewAlias(name, alias)
|
||||||
except RecursiveAlias:
|
except RecursiveAlias:
|
||||||
|
Loading…
Reference in New Issue
Block a user