return std::make_pair(false, parameter);
}
- bool CheckTimeStamp(time_t theirs, time_t ours, const std::string &their_param, const std::string &our_param, Channel* channel)
- {
- /* When TS is equal, the alphabetically later one wins */
- return (their_param < our_param);
- }
-
ModeAction OnModeChange(User* source, User* dest, Channel* channel, std::string ¶meter, bool adding, bool)
{
if (!adding)
class ModuleKickNoRejoin : public Module
{
- KickRejoin* kr;
+ KickRejoin kr;
public:
ModuleKickNoRejoin(InspIRCd* Me)
- : Module(Me)
+ : Module(Me), kr(Me)
{
-
- kr = new KickRejoin(ServerInstance);
- if (!ServerInstance->Modes->AddMode(kr))
+ if (!ServerInstance->Modes->AddMode(&kr))
throw ModuleException("Could not add new modes!");
Implementation eventlist[] = { I_OnCleanup, I_OnChannelDelete, I_OnUserPreJoin, I_OnUserKick };
ServerInstance->Modules->Attach(eventlist, this, 4);
virtual ~ModuleKickNoRejoin()
{
- ServerInstance->Modes->DelMode(kr);
- delete kr;
+ ServerInstance->Modes->DelMode(&kr);
}
virtual Version GetVersion()