From a75afb597b8b4f7e342c393bc3dea868e66f9b4c Mon Sep 17 00:00:00 2001 From: Sadie Powell Date: Thu, 22 Feb 2024 13:23:18 +0000 Subject: Add the IRCv3 reply tag to messages sent as responses to a user. --- src/command.cpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'src/command.cpp') diff --git a/src/command.cpp b/src/command.cpp index 2ac6cb7d7..dc24dac0b 100644 --- a/src/command.cpp +++ b/src/command.cpp @@ -17,6 +17,11 @@ #include "regchannel.h" #include "channels.h" +void CommandReply::SendMessage(CommandSource& source, const Anope::string &msg) +{ + SendMessage(source.service, msg); +} + CommandSource::CommandSource(const Anope::string &n, User *user, NickCore *core, CommandReply *r, BotInfo *bi, const Anope::string &m) : nick(n) , u(user) @@ -119,7 +124,7 @@ void CommandSource::Reply(const Anope::string &message) sepstream sep(translated_message, '\n', true); Anope::string tok; while (sep.GetToken(tok)) - this->reply->SendMessage(this->service, tok); + this->reply->SendMessage(*this, tok); } Command::Command(Module *o, const Anope::string &sname, size_t minparams, size_t maxparams) : Service(o, "Command", sname), max_params(maxparams), min_params(minparams), module(o) -- cgit