summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/modes/cmode_k.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/modes/cmode_k.cpp b/src/modes/cmode_k.cpp
index 8e7692efc..ec17a7468 100644
--- a/src/modes/cmode_k.cpp
+++ b/src/modes/cmode_k.cpp
@@ -80,7 +80,8 @@ ModeAction ModeChannelKey::OnModeChange(User* source, User*, Channel* channel, s
{
std::string ckey;
ckey.assign(parameter, 0, 32);
- channel->SetMode('k', ckey.c_str());
+ channel->SetModeParam('k', ckey.c_str(), adding);
+ channel->SetMode('k', adding);
parameter = ckey;
return MODEACTION_ALLOW;
}