- Filter* f = (Filter*)index->second;
- std::string target = "";
-
- if (target_type == TYPE_USER)
- {
- userrec* t = (userrec*)dest;
- target = std::string(t->nick);
- }
- else if (target_type == TYPE_CHANNEL)
- {
- chanrec* t = (chanrec*)dest;
- target = std::string(t->name);
- }
-
- if (f->action == "block")
- {
- Srv->SendOpers(std::string("FILTER: ")+std::string(user->nick)+
- std::string(" had their notice filtered, target was ")+
- target+": "+f->reason);
- user->WriteServ("NOTICE "+std::string(user->nick)+
- " :Your notice has been filtered and opers notified: "+f->reason);
- }
- Srv->Log(DEFAULT,std::string("FILTER: ")+std::string(user->nick)+
- std::string(" had their notice filtered, target was ")+
- target+": "+f->reason+" Action: "+f->action);
-
- if (f->action == "kill")
- {
- userrec::QuitUser(user,f->reason);
- }
- return 1;