From 233c624056ade467c7b4b4dbebbf62628f00cc28 Mon Sep 17 00:00:00 2001 From: Peter Powell Date: Sun, 15 Apr 2018 22:37:04 +0100 Subject: Use an oper priv instead of a config flag for overriding callerid. --- src/modules/m_callerid.cpp | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'src/modules/m_callerid.cpp') diff --git a/src/modules/m_callerid.cpp b/src/modules/m_callerid.cpp index d69f5606f..f43dd448d 100644 --- a/src/modules/m_callerid.cpp +++ b/src/modules/m_callerid.cpp @@ -330,7 +330,6 @@ class ModuleCallerID : public Module SimpleUserModeHandler myumode; // Configuration variables: - bool operoverride; // Operators can override callerid. bool tracknick; // Allow ACCEPT entries to update with nick changes. unsigned int notify_cooldown; // Seconds between notifications. @@ -384,7 +383,7 @@ public: if (!dest->IsModeSet(myumode) || (user == dest)) return MOD_RES_PASSTHRU; - if (operoverride && user->IsOper()) + if (user->HasPrivPermission("users/callerid-override")) return MOD_RES_PASSTHRU; callerid_data* dat = cmd.extInfo.get(dest, true); @@ -420,7 +419,6 @@ public: { ConfigTag* tag = ServerInstance->Config->ConfValue("callerid"); cmd.maxaccepts = tag->getInt("maxaccepts", 16); - operoverride = tag->getBool("operoverride"); tracknick = tag->getBool("tracknick"); notify_cooldown = tag->getDuration("cooldown", 60); } -- cgit v1.3.1-10-gc9f91