added "all" argument to cmd_invitemeall to get invited to all channels (not only...
authorpk910 <philipp@zoelle1.de>
Mon, 24 Sep 2012 12:01:41 +0000 (14:01 +0200)
committerpk910 <philipp@zoelle1.de>
Mon, 24 Sep 2012 12:01:41 +0000 (14:01 +0200)
src/modules/NeonServ.mod/cmd_neonserv_invitemeall.c

index 9f5b56da67c60cc3ceb9b4475554a01bf3222a82..c7d33409840235c53206c94a64c024297fbdd672 100644 (file)
@@ -31,7 +31,7 @@ CMD_BIND(neonserv_cmd_invitemeall) {
     struct ClientSocket *bot;
     while((chanuserrow = mysql_fetch_row(res)) != NULL) {
         int userflags = atoi(chanuserrow[1]);
-        if(!(userflags & DB_CHANUSER_AUTOINVITE)) continue;
+        if(!(argc && !stricmp(argv[0], "all")) && !(userflags & DB_CHANUSER_AUTOINVITE)) continue;
         if(!(chan = getChanByName(chanuserrow[2]))) continue; //no bot is in the channel
         if((bchanuser = getChanUser(client->user, chan)) && (bchanuser->flags & CHANUSERFLAG_OPPED))
             bot = client;