public:
GenericCap cap;
ModuleNamesX() : cap(this, "multi-prefix")
+ {
+ }
+
+ void init()
{
Implementation eventlist[] = { I_OnPreCommand, I_OnNamesListItem, I_On005Numeric, I_OnEvent, I_OnSendWhoLine };
- ServerInstance->Modules->Attach(eventlist, this, 5);
+ ServerInstance->Modules->Attach(eventlist, this, sizeof(eventlist)/sizeof(Implementation));
}
// Try to find this channel
std::string channame = line.substr(a, b-a);
- Channel* chan = ServerInstance->FindChan(channame.c_str());
+ Channel* chan = ServerInstance->FindChan(channame);
if (!chan)
return;