summaryrefslogtreecommitdiff
path: root/modules/commands/cs_set.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'modules/commands/cs_set.cpp')
-rw-r--r--modules/commands/cs_set.cpp8
1 files changed, 7 insertions, 1 deletions
diff --git a/modules/commands/cs_set.cpp b/modules/commands/cs_set.cpp
index f20866e2a..e3d2493ff 100644
--- a/modules/commands/cs_set.cpp
+++ b/modules/commands/cs_set.cpp
@@ -1147,7 +1147,7 @@ class CSSet : public Module
{
this->SetAuthor("Anope");
- Implementation i[] = { I_OnReload, I_OnChanRegistered, I_OnCheckKick };
+ Implementation i[] = { I_OnReload, I_OnChanRegistered, I_OnCheckKick, I_OnDelChan };
ModuleManager::Attach(i, this, sizeof(i) / sizeof(Implementation));
this->OnReload();
@@ -1175,6 +1175,12 @@ class CSSet : public Module
return EVENT_CONTINUE;
}
+
+ void OnDelChan(ChannelInfo *ci) anope_override
+ {
+ if (ci->c && ci->HasExt("PERSIST"))
+ ci->c->RemoveMode(ci->WhoSends(), "PERM", "", false);
+ }
};
MODULE_INIT(CSSet)