summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/modules/m_chanprotect.cpp8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/modules/m_chanprotect.cpp b/src/modules/m_chanprotect.cpp
index 2951e711b..5a6e4853d 100644
--- a/src/modules/m_chanprotect.cpp
+++ b/src/modules/m_chanprotect.cpp
@@ -86,12 +86,12 @@ class FounderProtectBase
if ((!theuser) || (!channel->HasUser(theuser)))
{
parameter = "";
- return theuser;
+ return NULL;
}
- return NULL;
+ return theuser;
}
- ModeAction HandleChange(userrec* source, userrec*theuser, bool adding, chanrec* channel, std::string &parameter)
+ ModeAction HandleChange(userrec* source, userrec* theuser, bool adding, chanrec* channel, std::string &parameter)
{
std::string item = extend+std::string(channel->name);
@@ -140,7 +140,9 @@ class ChanFounder : public ModeHandler, public FounderProtectBase
userrec* theuser = FounderProtectBase::FindAndVerify(parameter, channel);
if (!theuser)
+ {
return MODEACTION_DENY;
+ }
// source is a server, or ulined, we'll let them +-q the user.
if ((ServerInstance->ULine(source->nick)) || (ServerInstance->ULine(source->server)) || (!*source->server) || (!IS_LOCAL(source)))