mirror of
https://github.com/inspircd/inspircd.git
synced 2025-03-10 02:59:01 -04:00
Use an oper priv instead of a config flag for overriding nonicks.
This commit is contained in:
parent
233c624056
commit
dec17a2e32
@ -27,6 +27,7 @@
|
||||
# - users/mass-message: allows opers with this priv to PRIVMSG and NOTICE to a server mask (e.g. NOTICE $*)
|
||||
# - users/samode-usermodes: allows opers with this priv to change the user modes of any other user using /SAMODE
|
||||
# PERMISSIONS:
|
||||
#. - channels/ignore-nonicks: allows opers with this priv to change their nick when on a +N channel.
|
||||
# - users/flood/no-fakelag: prevents opers from being penalized with fake lag for flooding (*NOTE)
|
||||
# - users/flood/no-throttle: allows opers with this priv to send commands without being throttled (*NOTE)
|
||||
# - users/flood/increased-buffers: allows opers with this priv to send and receive data without worrying about being disconnected for exceeding limits (*NOTE)
|
||||
|
@ -26,7 +26,6 @@ class ModuleNoNickChange : public Module
|
||||
{
|
||||
CheckExemption::EventProvider exemptionprov;
|
||||
SimpleChannelModeHandler nn;
|
||||
bool override;
|
||||
public:
|
||||
ModuleNoNickChange()
|
||||
: exemptionprov(this)
|
||||
@ -55,7 +54,7 @@ class ModuleNoNickChange : public Module
|
||||
if (res == MOD_RES_ALLOW)
|
||||
continue;
|
||||
|
||||
if (override && user->IsOper())
|
||||
if (user->HasPrivPermission("channels/ignore-nonicks"))
|
||||
continue;
|
||||
|
||||
if (!curr->GetExtBanStatus(user, 'N').check(!curr->IsModeSet(nn)))
|
||||
@ -68,11 +67,6 @@ class ModuleNoNickChange : public Module
|
||||
|
||||
return MOD_RES_PASSTHRU;
|
||||
}
|
||||
|
||||
void ReadConfig(ConfigStatus& status) CXX11_OVERRIDE
|
||||
{
|
||||
override = ServerInstance->Config->ConfValue("nonicks")->getBool("operoverride", false);
|
||||
}
|
||||
};
|
||||
|
||||
MODULE_INIT(ModuleNoNickChange)
|
||||
|
Loading…
x
Reference in New Issue
Block a user