added oper messages
[srvx.git] / src / mod-watchdog.c
index 0866b0076d37be6081c3bc0feafee95c78be78a0..e6bb84c8c56095930f633dd647cff7b7952ef078 100644 (file)
@@ -84,7 +84,9 @@ struct watchdog_channel {
 #define BADACTION_KILL   2
 #define BADACTION_GLINE  3
 
-#define WDMSG_BADWORD_ALERT "%s used badword '%s' in channel: %s"
+#define WDMSG_BADWORD_ALERT "%s used badword '%s' in channel: %s."
+#define WDMSG_REGISTER_SUCCESS "$b%s$b is now registered with %s by %s."
+#define WDMSG_UNREG_SUCCESS "$b%s$b is now unregistered by %s."
 
 static struct {
     const char *nick;
@@ -356,7 +358,7 @@ static MODCMD_FUNC(cmd_register)
 
     add_channel(channel->name);
     reply("WDMSG_REGISTER_SUCCESS", channel->name, watchdog->nick);
-    watchdog_oper_message("WDMSG_REGISTER_SUCCESS", channel->name, watchdog->nick);
+    watchdog_oper_message(WDMSG_REGISTER_SUCCESS, channel->name, watchdog->nick, user->handle_info->handle);
     return 1;
 }
 
@@ -378,7 +380,7 @@ static MODCMD_FUNC(cmd_unregister)
         DelChannelUser(watchdog, channel, reason, 0);
         dict_remove(chanlist, channel->name);
         reply("CSMSG_UNREG_SUCCESS", channel->name);
-        watchdog_oper_message("CSMSG_UNREG_SUCCESS", channel->name);
+        watchdog_oper_message(WDMSG_UNREG_SUCCESS, channel->name, user->handle_info->handle);
         return 1;
     } else {
         reply("WDMSG_NOT_REGISTERED", channel->name, watchdog->nick);