diff --git a/src/Channel.py b/src/Channel.py index 58e8a4ea0..00375d6b7 100755 --- a/src/Channel.py +++ b/src/Channel.py @@ -547,19 +547,14 @@ class Channel(callbacks.Privmsg): irc.reply(utils.commaAndify(imap(repr, L))) ignores = wrap(ignores, [('checkChannelCapability', 'op')]) - def addcapability(self, irc, msg, args, channel, hostmask, capabilities): - """[] [ ...] + def addcapability(self, irc, msg, args, channel, user, capabilities): + """[] [ ...] If you have the #channel,op capability, this will give the user - currently identified as (or the user to whom maps) + (or the user to whom maps) the capability in the channel. is only necessary if the message isn't sent in the channel itself. """ - try: - id = ircdb.users.getUserId(hostmask) - user = ircdb.users.getUser(id) - except KeyError: - irc.errorNoUser(Raise=True) for c in capabilities.split(): c = ircdb.makeChannelCapability(channel, c) user.addCapability(c) @@ -568,7 +563,7 @@ class Channel(callbacks.Privmsg): addcapability = wrap(addcapability, [('checkChannelCapability', 'op'), 'otherUser', 'capability']) - def removecapability(self, irc, msg, args, channel, hostmask, capabilities): + def removecapability(self, irc, msg, args, channel, user, capabilities): """[] [ ...] If you have the #channel,op capability, this will take from the user @@ -576,11 +571,6 @@ class Channel(callbacks.Privmsg): the capability in the channel. is only necessary if the message isn't sent in the channel itself. """ - try: - id = ircdb.users.getUserId(hostmask) - except KeyError: - irc.errorNoUser(Raise=True) - user = ircdb.users.getUser(id) fail = [] for c in capabilities.split(): cap = ircdb.makeChannelCapability(channel, c)