- /* Only opers can receive snotices, so we iterate the oper list */
- for (std::list<User*>::iterator i = ServerInstance->all_opers.begin(); i != ServerInstance->all_opers.end(); i++)
+ if (this->LastMessage.empty())
+ return;
+
+ ServerInstance->Logs->Log("snomask", DEFAULT, "%s: %s", this->Description.c_str(), this->LastMessage.c_str());
+ if (Count > 1)
+ ServerInstance->Logs->Log("snomask", DEFAULT, "%s: (last message repeated %u times)", this->Description.c_str(), Count);
+
+
+ int MOD_RESULT = 0;
+ char mysnomask = MySnomask;
+ std::string desc = this->Description;
+
+ FOREACH_RESULT(I_OnSendSnotice, OnSendSnotice(mysnomask, desc, this->LastMessage));
+
+ if (MOD_RESULT != 1) // 1 blocks the message