diff --git a/coremods/exttargets.py b/coremods/exttargets.py index c44852c..eac97ec 100644 --- a/coremods/exttargets.py +++ b/coremods/exttargets.py @@ -74,7 +74,7 @@ def ircop(irc, host, uid): if len(groups) == 1: # 1st scenario. - return irc.is_oper(uid, allowAuthed=False) + return irc.is_oper(uid) else: # 2nd scenario. Use match_host (ircmatch) to match the opertype glob to the opertype. return irc.match_host(groups[1], irc.users[uid].opertype) diff --git a/coremods/login.py b/coremods/login.py index 79d3824..5cd03b3 100644 --- a/coremods/login.py +++ b/coremods/login.py @@ -78,7 +78,7 @@ def _irc_try_login(irc, source, username, skip_checks=False): irc.name, username, irc.get_hostmask(source), ', '.join(network_filter), irc.name) raise utils.NotAuthorizedError("Account is not authorized to login on this network.") - elif require_oper and not irc.is_oper(source, allowAuthed=False): + elif require_oper and not irc.is_oper(source): log.warning("(%s) Failed login to %r from %s (needs oper)", irc.name, username, irc.get_hostmask(source)) raise utils.NotAuthorizedError("You must be opered.") diff --git a/plugins/antispam.py b/plugins/antispam.py index 6990325..3b77757 100644 --- a/plugins/antispam.py +++ b/plugins/antispam.py @@ -19,7 +19,7 @@ def _punish(irc, target, channel, punishment, reason): if target not in irc.users: log.warning("(%s) antispam: got target %r that isn't a user?", irc.name, target) return False - elif irc.is_oper(target, allowAuthed=False): + elif irc.is_oper(target): log.debug("(%s) antispam: refusing to punish oper %s/%s", irc.name, target, irc.get_friendly_name(target)) return False diff --git a/plugins/relay.py b/plugins/relay.py index 8cdda42..2d7c03f 100644 --- a/plugins/relay.py +++ b/plugins/relay.py @@ -1202,7 +1202,7 @@ def handle_relay_whois(irc, source, command, args): setting = conf.conf.get('relay', {}).get(infoline, '').lower() if setting == 'all': return True - elif setting == 'opers' and irc.is_oper(source, allowAuthed=False): + elif setting == 'opers' and irc.is_oper(source): return True return False diff --git a/protocols/clientbot.py b/protocols/clientbot.py index e5176e4..98dd7e6 100644 --- a/protocols/clientbot.py +++ b/protocols/clientbot.py @@ -800,12 +800,12 @@ class ClientbotWrapperProtocol(IRCCommonProtocol): if self.serverdata.get('track_oper_statuses'): if '*' in status: # Track IRCop status - if not self.is_oper(uid, allowAuthed=False): + if not self.is_oper(uid): # Don't send duplicate oper ups if the target is already oper. self.apply_modes(uid, [('+o', None)]) self.call_hooks([uid, 'MODE', {'target': uid, 'modes': {('+o', None)}}]) self.call_hooks([uid, 'CLIENT_OPERED', {'text': 'IRC Operator'}]) - elif self.is_oper(uid, allowAuthed=False) and not self.is_internal_client(uid): + elif self.is_oper(uid) and not self.is_internal_client(uid): # Track deopers self.apply_modes(uid, [('-o', None)]) self.call_hooks([uid, 'MODE', {'target': uid, 'modes': {('-o', None)}}])