mirror of
https://github.com/inspircd/inspircd.git
synced 2025-03-10 11:09:04 -04:00
Fix +P channels being deleted when the final user /QUITs, thanks SnoFox
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11161 e03df62e-2008-0410-955e-edbf42e46eb7
This commit is contained in:
parent
789e43b40d
commit
f0552b8d76
@ -1964,6 +1964,10 @@ void User::PurgeEmptyChannels()
|
||||
chan_hash::iterator i2 = ServerInstance->chanlist->find(thischan->name);
|
||||
if (i2 != ServerInstance->chanlist->end())
|
||||
{
|
||||
int MOD_RESULT = 0;
|
||||
FOREACH_RESULT_I(ServerInstance,I_OnChannelPreDelete, OnChannelPreDelete(i2->second));
|
||||
if (MOD_RESULT == 1)
|
||||
continue; // delete halted by module
|
||||
FOREACH_MOD(I_OnChannelDelete,OnChannelDelete(i2->second));
|
||||
delete i2->second;
|
||||
ServerInstance->chanlist->erase(i2);
|
||||
|
Loading…
x
Reference in New Issue
Block a user