Another year is about to end... So we have to update these damn copyright information :P
[NeonServV5.git] / src / cmd_global_delbot.c
index 1a37dd4570536f5bfef414665d7868582bdfa3d7..b017f127c0bb3436f853134e2d03d71b54f1894d 100644 (file)
@@ -1,5 +1,5 @@
-/* cmd_global_delbot.c - NeonServ v5.2
- * Copyright (C) 2011  Philipp Kreil (pk910)
+/* cmd_global_delbot.c - NeonServ v5.3
+ * Copyright (C) 2011-2012  Philipp Kreil (pk910)
  * 
  * This program is free software: you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
@@ -32,6 +32,8 @@ CMD_BIND(global_cmd_delbot) {
     }
     int botid = atoi(row[0]);
     printf_mysql_query("DELETE FROM `bots` WHERE `id` = '%s'", row[0]);
+    printf_mysql_query("DELETE FROM `bot_binds` WHERE `botid` = '%s'", row[0]);
+    printf_mysql_query("DELETE FROM `bot_channels` WHERE `botid` = '%s'", row[0]);
     for(client = getBots(0, NULL); client; client = getBots(0, client)) {
         if(client->clientid == botid) {
             close_socket(client);