#include <string.h>
#include <ctype.h>
-#include "../lib/sstring.h"
-#include "../lib/irc_string.h"
-#include "../channel/channel.h"
-#include "../localuser/localuserchannel.h"
-#include "../core/schedule.h"
-#include "../nick/nick.h"
-
-
#include "hchannel.h"
#include "haccount.h"
#include "helpmod.h"
while (hchan->htickets)
hticket_del(hchan->htickets, hchan);
- localpartchannel(helpmodnick, hchan->real_channel);
+ localpartchannel(helpmodnick, hchan->real_channel, "Channel Removed");
free(hchan);
if (huser_on_channel((*hchanuser)->husr, hchan)->flags & H_IDLE_WARNING)
{
const char *banmask = hban_ban_string((*hchanuser)->husr->real_user, HBAN_HOST);
- helpmod_setban(hchan, banmask, time(NULL) + 10 * HDEF_m, MCB_ADD, HLAZY);
+ int bantime = 10;
+ helpmod_setban(hchan, banmask, time(NULL) + bantime * HDEF_m, MCB_ADD, HLAZY);
- helpmod_kick(hchan, (*hchanuser)->husr, "Please do not idle in %s", hchannel_get_name(hchan));
+ helpmod_kick(hchan, (*hchanuser)->husr, "Please do not idle in %s (%dmin anti-idle tempban). If you still require assistance, please try again later.", hchannel_get_name(hchan), bantime);
continue;
}
else
break;
}
*hchanuser = tmp;
+ assert(*hchanuser != NULL);
(*hchanuser)->next = NULL;
if (on_desk(husr, huserchan))
{