1
0
mirror of https://github.com/anope/anope.git synced 2026-06-27 01:56:38 +02:00

Move nickserv/set/message to a new module, kill options:useprivmsg.

This commit is contained in:
Sadie Powell
2024-10-22 14:14:40 +01:00
parent 57ac7cb4db
commit 435ce51196
8 changed files with 161 additions and 142 deletions
+4 -4
View File
@@ -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)