From f4ddd40badd2eb5181dadc1dcd59d7200738bf24 Mon Sep 17 00:00:00 2001 From: w00t Date: Thu, 14 Feb 2008 12:03:32 +0000 Subject: More OnRawMode fix git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8932 e03df62e-2008-0410-955e-edbf42e46eb7 --- src/mode.cpp | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/src/mode.cpp b/src/mode.cpp index 48777a7bf..4d0a812e8 100644 --- a/src/mode.cpp +++ b/src/mode.cpp @@ -306,20 +306,12 @@ void ModeParser::Process(const char** parameters, int pcnt, User *user, bool ser { unsigned char mletter = *mode; - int MOD_RESULT = 0; - FOREACH_RESULT(I_OnRawMode, OnRawMode(user, targetchannel, *mode, "", true, 0)); - if (MOD_RESULT == ACR_DENY) - { - mode++; - continue; - } - if (*mode == '+') { mode++; continue; } - + /* Ensure the user doesnt request the same mode twice, * so they cant flood themselves off out of idiocy. */ @@ -338,6 +330,14 @@ void ModeParser::Process(const char** parameters, int pcnt, User *user, bool ser if ((mh) && (mh->IsListMode())) { + int MOD_RESULT = 0; + FOREACH_RESULT(I_OnRawMode, OnRawMode(user, targetchannel, *mode, "", true, 0)); + if (MOD_RESULT == ACR_DENY) + { + mode++; + continue; + } + if (ServerInstance->Config->HideModeLists[mletter] && (targetchannel->GetStatus(user) < STATUS_HOP)) { user->WriteServ("482 %s %s :Only half-operators and above may view the +%c list",user->nick, targetchannel->name, *mode++); -- cgit v1.2.3