allow god users overriding the cross-channel restriction
authorpk910 <philipp@zoelle1.de>
Sun, 25 Dec 2011 22:03:45 +0000 (23:03 +0100)
committerpk910 <philipp@zoelle1.de>
Sun, 25 Dec 2011 22:03:45 +0000 (23:03 +0100)
src/modcmd.c

index 03b24d8351b984f6a9b53df311e9c79ce1ee0292..5a4de9ad1db3bd2e2c6d361379406a795b5f367f 100644 (file)
@@ -398,8 +398,12 @@ static void handle_command_async(struct ClientSocket *client, struct UserNode *u
             requested_uaccess = 1;
             uaccess = getChannelAccess(user, chan);
             if(!uaccess) {
-                reply(tmp_text_client, user, "MODCMD_CROSSCHAN", chan->name);
-                return;
+                if(isGodMode(user)) {
+                    eventflags |= CMDFLAG_OPLOG;
+                } else {
+                    reply(tmp_text_client, user, "MODCMD_CROSSCHAN", chan->name);
+                    return;
+                }
             }
         }
     }