summaryrefslogtreecommitdiff
path: root/src/cmd_privmsg.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/cmd_privmsg.cpp')
-rw-r--r--src/cmd_privmsg.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/cmd_privmsg.cpp b/src/cmd_privmsg.cpp
index f3295df07..04f500951 100644
--- a/src/cmd_privmsg.cpp
+++ b/src/cmd_privmsg.cpp
@@ -67,12 +67,12 @@ CmdResult cmd_privmsg::Handle (const char** parameters, int pcnt, userrec *user)
{
if (IS_LOCAL(user))
{
- if ((chan->modes[CM_NOEXTERNAL]) && (!chan->HasUser(user)))
+ if ((chan->IsModeSet('n')) && (!chan->HasUser(user)))
{
user->WriteServ("404 %s %s :Cannot send to channel (no external messages)", user->nick, chan->name);
return CMD_FAILURE;
}
- if ((chan->modes[CM_MODERATED]) && (chan->GetStatus(user) < STATUS_VOICE))
+ if ((chan->IsModeSet('m')) && (chan->GetStatus(user) < STATUS_VOICE))
{
user->WriteServ("404 %s %s :Cannot send to channel (+m)", user->nick, chan->name);
return CMD_FAILURE;