summaryrefslogtreecommitdiff
path: root/src/modules/m_channelban.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/modules/m_channelban.cpp')
-rw-r--r--src/modules/m_channelban.cpp10
1 files changed, 2 insertions, 8 deletions
diff --git a/src/modules/m_channelban.cpp b/src/modules/m_channelban.cpp
index 3260c0fa4..300caa123 100644
--- a/src/modules/m_channelban.cpp
+++ b/src/modules/m_channelban.cpp
@@ -42,15 +42,9 @@ class ModuleBadChannelExtban : public Module
}
for (UCListIter i = user->chans.begin(); i != user->chans.end(); i++)
{
- if (InspIRCd::Match((**i).name, rm))
+ if (InspIRCd::Match((*i)->chan->name, rm))
{
- if (status)
- {
- Membership* memb = (**i).GetUser(user);
- if (memb && memb->hasMode(status))
- return MOD_RES_DENY;
- }
- else
+ if (!status || (*i)->hasMode(status))
return MOD_RES_DENY;
}
}