diff options
| author | 2020-04-05 19:10:48 +0100 | |
|---|---|---|
| committer | 2020-04-05 19:10:48 +0100 | |
| commit | f28c467e95f68f7a1767ebb0bc6f6f12ae407f3a (patch) | |
| tree | ef53d929a3b6edb3eb4b72c9d19cb6ae7983edbe /src/modules/m_restrictchans.cpp | |
| parent | Vendor the optional-lite library. (diff) | |
| download | inspircd++-f28c467e95f68f7a1767ebb0bc6f6f12ae407f3a.tar.gz inspircd++-f28c467e95f68f7a1767ebb0bc6f6f12ae407f3a.tar.bz2 inspircd++-f28c467e95f68f7a1767ebb0bc6f6f12ae407f3a.zip | |
Send ERR_BANNEDFROMCHAN when a user can't create a restricted channel.
Closes #1772.
Diffstat (limited to 'src/modules/m_restrictchans.cpp')
| -rw-r--r-- | src/modules/m_restrictchans.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/modules/m_restrictchans.cpp b/src/modules/m_restrictchans.cpp index ae1091516..7bacda653 100644 --- a/src/modules/m_restrictchans.cpp +++ b/src/modules/m_restrictchans.cpp @@ -80,7 +80,10 @@ class ModuleRestrictChans : public Module { // channel does not yet exist (record is null, about to be created IF we were to allow it) if (!chan && !CanCreateChannel(user, cname)) + { + user->WriteNumeric(ERR_BANNEDFROMCHAN, cname, "You are not allowed to create new channels."); return MOD_RES_DENY; + } return MOD_RES_PASSTHRU; } |
