]> git.netwichtig.de Git - user/henk/code/inspircd.git/commitdiff
Fix exposing the ban reason when an xline is found in the bancache.
authorPeter Powell <petpow@saberuk.com>
Wed, 26 Sep 2018 22:53:29 +0000 (23:53 +0100)
committerPeter Powell <petpow@saberuk.com>
Sun, 4 Nov 2018 10:02:28 +0000 (10:02 +0000)
src/usermanager.cpp

index 2cb7ad51117a4743eb8835f6cd5c79dba9456d6c..f62d28faab3d83c8dad12a88454d5e73590ee5c6 100644 (file)
@@ -117,7 +117,11 @@ void UserManager::AddUser(int socket, ListenSocket* via, irc::sockets::sockaddrs
                        ServerInstance->Logs->Log("BANCACHE", DEBUG, std::string("BanCache: Positive hit for ") + New->GetIPString());
                        if (!ServerInstance->Config->MoronBanner.empty())
                                New->WriteServ("NOTICE %s :*** %s", New->nick.c_str(), ServerInstance->Config->MoronBanner.c_str());
-                       this->QuitUser(New, b->Reason);
+
+                       if (ServerInstance->Config->HideBans)
+                               this->QuitUser(New, b->Type + "-Lined", b->Reason.c_str());
+                       else
+                               this->QuitUser(New, b->Reason);
                        return;
                }
                else