summaryrefslogtreecommitdiff
path: root/src/modes/umode_n.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/modes/umode_n.cpp')
-rw-r--r--src/modes/umode_n.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/modes/umode_n.cpp b/src/modes/umode_n.cpp
index 7bb8dbbf0..f2c838454 100644
--- a/src/modes/umode_n.cpp
+++ b/src/modes/umode_n.cpp
@@ -18,6 +18,12 @@ ModeAction ModeUserServerNoticeMask::OnModeChange(userrec* source, userrec* dest
if (adding)
{
parameter = dest->ProcessNoticeMasks(parameter.c_str());
+ dest->modes[UM_SNOMASK] = true;
+ if (!dest->modes[UM_SERVERNOTICE])
+ {
+ const char* newmodes[] = { dest->nick, "+s" };
+ ServerInstance->Modes->Process(newmodes, 2, source, true);
+ }
return MODEACTION_ALLOW;
}
else if (dest->modes[UM_SNOMASK] != false)