summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMatt Schatz <genius3000@g3k.solutions>2020-04-04 02:58:59 -0600
committerMatt Schatz <genius3000@g3k.solutions>2020-04-04 02:58:59 -0600
commitcad2f3f979b2fc45bcfa7c7b7652bbe201a5b0a0 (patch)
tree93ecca2bde0d996b5f338034586121a90968babf /src
parent235a986964ff09dcc8662ea078518cad6bfbf11b (diff)
Ignore clients on ulined servers when counting invisible users.
This is in addition to 4cc992f.
Diffstat (limited to 'src')
-rw-r--r--src/coremods/core_lusers.cpp9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/coremods/core_lusers.cpp b/src/coremods/core_lusers.cpp
index 62a6ef48c..7587a3443 100644
--- a/src/coremods/core_lusers.cpp
+++ b/src/coremods/core_lusers.cpp
@@ -120,6 +120,9 @@ public:
if (dest->registered != REG_ALL)
return;
+ if (dest->server->IsULine())
+ return;
+
if (adding)
invisible++;
else
@@ -141,7 +144,7 @@ class ModuleLusers : public Module
for (user_hash::const_iterator i = users.begin(); i != users.end(); ++i)
{
User* u = i->second;
- if (u->IsModeSet(invisiblemode))
+ if (!u->server->IsULine() && u->IsModeSet(invisiblemode))
c++;
}
return c;
@@ -159,13 +162,13 @@ class ModuleLusers : public Module
void OnPostConnect(User* user) CXX11_OVERRIDE
{
counters.UpdateMaxUsers();
- if (user->IsModeSet(invisiblemode))
+ if (!user->server->IsULine() && user->IsModeSet(invisiblemode))
counters.invisible++;
}
void OnUserQuit(User* user, const std::string& message, const std::string& oper_message) CXX11_OVERRIDE
{
- if (user->IsModeSet(invisiblemode))
+ if (!user->server->IsULine() && user->IsModeSet(invisiblemode))
counters.invisible--;
}