Skip to content
This repository has been archived by the owner on Mar 14, 2023. It is now read-only.

Commit

Permalink
[SECURITY] Actually fix (#3)
Browse files Browse the repository at this point in the history
  • Loading branch information
RhinosF1 authored Oct 12, 2020
1 parent 122471c commit be0c90e
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@

setup(
name='sopel_plugins.channelmgnt',
version='1.0.2',
version='1.0.3',
description='Channelmgnt plugin for Sopel',
long_description=readme,
long_description_content_type='text/markdown', # This is important!
Expand Down
6 changes: 4 additions & 2 deletions sopel_channelmgnt/channelmgnt/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -84,13 +84,15 @@ def makemodechange(bot, trigger, mode, isusermode=False, isbqmode=False, selfsaf
bot.say('Attempting to OP...')
bot.say('op ' + trigger.sender, 'ChanServ')
time.sleep(1)
if isusermode and not trigger.group(2):
if isusermode and not trigger.group(2) and selfsafe:
bot.write(['MODE', trigger.sender, mode, trigger.nick])
elif isusermode and not trigger.group(2) and trigger.account in chanops:
bot.write(['MODE', trigger.sender, mode, trigger.nick])
elif isusermode and trigger.account in chanops:
bot.write(['MODE', trigger.sender, mode, trigger.group(2)])
elif isbqmode and trigger.account in chanops:
bot.write(['MODE', trigger.sender, mode, parse_host_mask(trigger.group().split())])
elif trigger.account in chanops and selfsafe:
elif trigger.account in chanops:
bot.write(['MODE', trigger.sender, mode])
else:
bot.reply('Access Denied. If in error, please contact the channel founder.')
Expand Down

0 comments on commit be0c90e

Please sign in to comment.