summaryrefslogtreecommitdiff
path: root/src/modules/m_override.cpp
diff options
context:
space:
mode:
authordanieldg <danieldg@e03df62e-2008-0410-955e-edbf42e46eb7>2009-09-13 20:31:11 +0000
committerdanieldg <danieldg@e03df62e-2008-0410-955e-edbf42e46eb7>2009-09-13 20:31:11 +0000
commitb4be0c94ab5fb7e5a7a799a195c78de072a5e315 (patch)
tree48dee3440b9bf1227f39ca2539d7fe55ad53df8b /src/modules/m_override.cpp
parentace3d85982f99ab04318ce705fd29fec5ffd7320 (diff)
Module API changes to use Membership* where sensible
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11699 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/modules/m_override.cpp')
-rw-r--r--src/modules/m_override.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/modules/m_override.cpp b/src/modules/m_override.cpp
index 0a445eff7..38864f400 100644
--- a/src/modules/m_override.cpp
+++ b/src/modules/m_override.cpp
@@ -132,16 +132,16 @@ class ModuleOverride : public Module
return MOD_RES_PASSTHRU;
}
- virtual ModResult OnUserPreKick(User* source, User* user, Channel* chan, const std::string &reason)
+ ModResult OnUserPreKick(User* source, Membership* memb, const std::string &reason)
{
if (IS_OPER(source) && CanOverride(source,"KICK"))
{
// If the kicker's status is less than the target's, or the kicker's status is less than or equal to voice
- if ((chan->GetPrefixValue(source) < chan->GetPrefixValue(user)) || (chan->GetPrefixValue(source) <= VOICE_VALUE))
+ if ((memb->chan->GetPrefixValue(source) < memb->getRank()) || (memb->chan->GetPrefixValue(source) <= VOICE_VALUE))
{
- ServerInstance->SNO->WriteGlobalSno('G',std::string(source->nick)+" used oper override to kick "+std::string(user->nick)+" on "+std::string(chan->name)+" ("+reason+")");
+ ServerInstance->SNO->WriteGlobalSno('G',std::string(source->nick)+" used oper override to kick "+std::string(memb->user->nick)+" on "+std::string(memb->chan->name)+" ("+reason+")");
+ return MOD_RES_ALLOW;
}
- return MOD_RES_ALLOW;
}
return MOD_RES_PASSTHRU;
}