Restrict Alias from making Aliases that coincide with plugin names.

This commit is contained in:
Jeremy Fincher 2004-02-03 16:47:18 +00:00
parent 9bf4f35a51
commit 0db9d6fd7d
1 changed files with 2 additions and 0 deletions

View File

@ -253,6 +253,8 @@ class Alias(callbacks.Privmsg):
raise AliasError, 'Names cannot contain spaces or square brackets.'
if conf.supybot.pipeSyntax() and '|' in name:
raise AliasError, 'Names cannot contain pipes.'
if irc.getCallback(name):
raise AliasError, 'Names cannot coincide with names of plugins.'
realName = callbacks.canonicalName(name)
if name != realName:
s = 'That name isn\'t valid. Try %r instead.' % realName