summaryrefslogtreecommitdiff
path: root/src/users.cpp
diff options
context:
space:
mode:
authorSadie Powell <sadie@witchery.services>2024-10-22 14:14:40 +0100
committerSadie Powell <sadie@witchery.services>2024-10-22 14:27:30 +0100
commit435ce511962e83a0581accd572dfa4e2c5722ab4 (patch)
tree78147b7be694087752d15bd48dcb75b0a1493f9b /src/users.cpp
parent57ac7cb4db63dee8e06d696ef6f973c337467040 (diff)
Move nickserv/set/message to a new module, kill options:useprivmsg.
Diffstat (limited to 'src/users.cpp')
-rw-r--r--src/users.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/users.cpp b/src/users.cpp
index e39114654..5f83420a4 100644
--- a/src/users.cpp
+++ b/src/users.cpp
@@ -839,10 +839,10 @@ bool User::BadPassword()
bool User::ShouldPrivmsg() const
{
// Send a PRIVMSG instead of a NOTICE if:
- // 1. options:useprivmsg is enabled.
- // 2. The user is not registered and msg is in nickserv:defaults.
- // 3. The user is registered and has set /ns set message on.
- return Config->UsePrivmsg && ((!nc && Config->DefPrivmsg) || (nc && nc->HasExt("MSG")));
+ // 1. The user is not registered and msg is in nickserv:defaults.
+ // 2. The user is registered and has set /ns set message on.
+ static ExtensibleRef<bool> msg("MSG");
+ return (!nc && Config->DefPrivmsg) || (nc && msg && msg->HasExt(nc));
}
User *User::Find(const Anope::string &name, bool nick_only)