From d0e839244593fb827d6eb0e4510470d978279497 Mon Sep 17 00:00:00 2001 From: Sadie Powell Date: Tue, 6 Oct 2020 15:13:14 +0100 Subject: Fix the global/global command showing the wrong origin nick. --- modules/commands/gl_global.cpp | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'modules/commands') diff --git a/modules/commands/gl_global.cpp b/modules/commands/gl_global.cpp index 061649d32..a79caf730 100644 --- a/modules/commands/gl_global.cpp +++ b/modules/commands/gl_global.cpp @@ -37,10 +37,16 @@ class CommandGLGlobal : public Command bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override { + Reference sender; + if (GService) + sender = GService->GetDefaultSender(); + if (!sender) + sender = source.service; + this->SendSyntax(source); source.Reply(" "); source.Reply(_("Allows Administrators to send messages to all users on the\n" - "network. The message will be sent from the nick \002%s\002."), source.service->nick.c_str()); + "network. The message will be sent from the nick \002%s\002."), sender->nick.c_str()); return true; } }; -- cgit