summaryrefslogtreecommitdiff
path: root/src/messages.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/messages.cpp')
-rw-r--r--src/messages.cpp11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/messages.cpp b/src/messages.cpp
index 178d376c3..c9ffd3c59 100644
--- a/src/messages.cpp
+++ b/src/messages.cpp
@@ -49,6 +49,17 @@ void Error::Run(MessageSource &source, const std::vector<Anope::string> &params)
Anope::Quitting = true;
}
+void Invite::Run(MessageSource &source, const std::vector<Anope::string> &params) anope_override
+{
+ User *targ = User::Find(params[0]);
+ Channel *c = Channel::Find(params[1]);
+
+ if (!targ || targ->server != Me || !c || c->FindUser(targ))
+ return;
+
+ FOREACH_MOD(I_OnInvite, OnInvite(source.GetUser(), c, targ));
+}
+
void Join::Run(MessageSource &source, const std::vector<Anope::string> &params)
{
User *user = source.GetUser();