aboutsummaryrefslogtreecommitdiffstats
path: root/modules/restrictchans.cpp
diff options
context:
space:
mode:
authorGravatar Sadie Powell2024-11-01 14:35:23 +0000
committerGravatar Sadie Powell2024-11-01 15:53:04 +0000
commit8a3aba4044ee10df332631c4c66ed60299566e58 (patch)
treeafb185a313dff83d61c26e3b95f47b62d3ab5694 /modules/restrictchans.cpp
parentDefault <options:extbanformat> to name. (diff)
parentUse fmtlib instead of iostream in ConvToStr where available. (diff)
Merge branch 'insp4' into master.
Diffstat (limited to 'modules/restrictchans.cpp')
-rw-r--r--modules/restrictchans.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/modules/restrictchans.cpp b/modules/restrictchans.cpp
index f39175aa2..346dcfc2d 100644
--- a/modules/restrictchans.cpp
+++ b/modules/restrictchans.cpp
@@ -83,7 +83,8 @@ public:
// channel does not yet exist (record is null, about to be created IF we were to allow it)
if (!override && !chan && !CanCreateChannel(user, cname))
{
- user->WriteNumeric(ERR_RESTRICTED, cname, "You are not allowed to create new channels.");
+ const auto* reason = allowregistered ? "logged into an account" : "a server operator";
+ user->WriteNumeric(ERR_RESTRICTED, cname, FMT::format("You must be {} to create new channels.", reason));
return MOD_RES_DENY;
}