From dab3dc93c177400a749400c61c9253be055b78e3 Mon Sep 17 00:00:00 2001 From: brain Date: Mon, 26 Dec 2005 13:05:44 +0000 Subject: Allow halfop to dehalfop themselves` git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@2652 e03df62e-2008-0410-955e-edbf42e46eb7 --- src/mode.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/mode.cpp') diff --git a/src/mode.cpp b/src/mode.cpp index de994dd5b..83e79c243 100644 --- a/src/mode.cpp +++ b/src/mode.cpp @@ -318,7 +318,8 @@ char* ModeParser::TakeHops(userrec *user,char *dest,chanrec *chan,int status) return NULL; if (MOD_RESULT == ACR_DEFAULT) { - if ((status < STATUS_OP) && (!is_uline(user->server))) + /* Tweak by Brain suggested by w00t, allow a halfop to dehalfop themselves */ + if ((user != d) && ((status < STATUS_OP) && (!is_uline(user->server)))) { WriteServ(user->fd,"482 %s %s :You are not a channel operator",user->nick, chan->name); return NULL; -- cgit v1.2.3