summaryrefslogtreecommitdiff
path: root/src/modules/m_uninvite.cpp
diff options
context:
space:
mode:
authorAttila Molnar <attilamolnar@hush.com>2015-11-03 12:40:24 +0100
committerAttila Molnar <attilamolnar@hush.com>2015-11-03 12:40:24 +0100
commit2c51a2bf17b6c377f0207f3d89b4b3f399fc0178 (patch)
tree93f446719933bcfcb2f3580fef778a37c70dc57e /src/modules/m_uninvite.cpp
parenta2461fb7e1c28e28e64b61256d7a547162a83f6e (diff)
parenta124a3783d8e8136b63f188bbd292c391811df54 (diff)
Merge branch 'master+invite'
Diffstat (limited to 'src/modules/m_uninvite.cpp')
-rw-r--r--src/modules/m_uninvite.cpp8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/modules/m_uninvite.cpp b/src/modules/m_uninvite.cpp
index 97ad841f1..e92688d1d 100644
--- a/src/modules/m_uninvite.cpp
+++ b/src/modules/m_uninvite.cpp
@@ -21,13 +21,17 @@
#include "inspircd.h"
+#include "modules/invite.h"
/** Handle /UNINVITE
*/
class CommandUninvite : public Command
{
+ Invite::API invapi;
public:
- CommandUninvite(Module* Creator) : Command(Creator,"UNINVITE", 2)
+ CommandUninvite(Module* Creator)
+ : Command(Creator, "UNINVITE", 2)
+ , invapi(Creator)
{
syntax = "<nick> <channel>";
TRANSLATE2(TR_NICK, TR_TEXT);
@@ -73,7 +77,7 @@ class CommandUninvite : public Command
LocalUser* lu = IS_LOCAL(u);
if (lu)
{
- if (!lu->RemoveInvite(c))
+ if (!invapi->Remove(lu, c))
{
user->SendText(":%s 505 %s %s %s :Is not invited to channel %s", user->server->GetName().c_str(), user->nick.c_str(), u->nick.c_str(), c->name.c_str(), c->name.c_str());
return CMD_FAILURE;