mirror of
https://github.com/anope/anope.git
synced 2026-06-26 20:16:38 +02:00
Unset +P from perm channels when expiring
This commit is contained in:
@@ -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)
|
||||
|
||||
Reference in New Issue
Block a user