diff options
author | danieldg <danieldg@e03df62e-2008-0410-955e-edbf42e46eb7> | 2009-10-12 18:12:48 +0000 |
---|---|---|
committer | danieldg <danieldg@e03df62e-2008-0410-955e-edbf42e46eb7> | 2009-10-12 18:12:48 +0000 |
commit | 579e707f017ca237d260165992f0b72bafba152c (patch) | |
tree | 3e3b6d77b90b505def180fec1dc3c040a00a4871 /src/modules/m_nonotice.cpp | |
parent | 480a798dbdafca245403ad357f5dba2aa4f73261 (diff) |
m_exemptchanops by jackmcbarn - channel mode +X to allow per-channel setting
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11855 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/modules/m_nonotice.cpp')
-rw-r--r-- | src/modules/m_nonotice.cpp | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/src/modules/m_nonotice.cpp b/src/modules/m_nonotice.cpp index 169626e61..188f08908 100644 --- a/src/modules/m_nonotice.cpp +++ b/src/modules/m_nonotice.cpp @@ -42,6 +42,7 @@ class ModuleNoNotice : public Module virtual ModResult OnUserPreNotice(User* user,void* dest,int target_type, std::string &text, char status, CUList &exempt_list) { + ModResult res; if ((target_type == TYPE_CHANNEL) && (IS_LOCAL(user))) { Channel* c = (Channel*)dest; @@ -52,11 +53,9 @@ class ModuleNoNotice : public Module // ulines are exempt. return MOD_RES_PASSTHRU; } - else if (CHANOPS_EXEMPT('T') && c->GetPrefixValue(user) == OP_VALUE) - { - // channel ops are exempt if set in conf. + FIRST_MOD_RESULT(OnChannelRestrictionApply, res, (c->GetUser(user),c,"nonotice")); + if (res == MOD_RES_ALLOW) return MOD_RES_PASSTHRU; - } else { user->WriteNumeric(ERR_CANNOTSENDTOCHAN, "%s %s :Can't send NOTICE to channel (+T set)",user->nick.c_str(), c->name.c_str()); |