1
0
mirror of https://github.com/anope/anope.git synced 2026-06-27 20:06:37 +02:00

Automatically quit bots when they are deleted

This commit is contained in:
Adam
2010-12-29 19:59:26 -05:00
parent 16cab979da
commit a36f14c1bf
4 changed files with 9 additions and 6 deletions
+8
View File
@@ -64,6 +64,14 @@ BotInfo::BotInfo(const Anope::string &nnick, const Anope::string &nuser, const A
BotInfo::~BotInfo()
{
// If we're synchronised with the uplink already, send the bot.
if (Me && Me->IsSynced())
{
ircdproto->SendQuit(this, NULL);
XLine x(this->nick);
ircdproto->SendSQLineDel(&x);
}
for (registered_channel_map::const_iterator it = RegisteredChannelList.begin(), it_end = RegisteredChannelList.end(); it != it_end; ++it)
{
ChannelInfo *ci = it->second;