diff --git a/plugins/relay.py b/plugins/relay.py index d14738c..caa021b 100644 --- a/plugins/relay.py +++ b/plugins/relay.py @@ -1775,6 +1775,8 @@ def link(irc, source, args): irc.error('Cannot link two channels on the same network.') return + permissions.checkPermissions(irc, source, ['relay.link']) + if source not in irc.channels[localchan].users: # Caller is not in the requested channel. log.debug('(%s) Source not in channel %s; protoname=%s', irc.name, localchan, irc.protoname) @@ -1796,8 +1798,6 @@ def link(irc, source, args): irc.error('You must be opped in %r to complete this operation.' % localchan) return - permissions.checkPermissions(irc, source, ['relay.link']) - if remotenet not in world.networkobjects: irc.error('No network named %r exists.' % remotenet) return