From c9ea418dd7f913ba1c2fbae49a82cf39d22e282f Mon Sep 17 00:00:00 2001 From: Sadie Powell Date: Mon, 20 Jul 2020 05:51:38 +0100 Subject: Show an error when an unprivileged user tries to mass-message. Closes #1790. --- src/coremods/core_message.cpp | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/coremods') diff --git a/src/coremods/core_message.cpp b/src/coremods/core_message.cpp index c950ab24b..26573c8bf 100644 --- a/src/coremods/core_message.cpp +++ b/src/coremods/core_message.cpp @@ -174,7 +174,10 @@ class CommandMessage : public Command // If the source isn't allowed to mass message users then reject // the attempt to mass-message users. if (!source->HasPrivPermission("users/mass-message")) + { + source->WriteNumeric(ERR_NOPRIVILEGES, "Permission Denied - You do not have the required operator privileges"); return CMD_FAILURE; + } // Extract the server glob match from the target parameter. std::string servername(parameters[0], 1); -- cgit v1.2.3