From 15a68932b6238cf52c3e86d1d029b0e65b8b755b Mon Sep 17 00:00:00 2001 From: Sadie Powell Date: Tue, 14 Dec 2021 15:54:51 +0000 Subject: If a user has a unique username then include it in bans. --- src/users.cpp | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src/users.cpp') diff --git a/src/users.cpp b/src/users.cpp index fc66cf70c..38e677226 100644 --- a/src/users.cpp +++ b/src/users.cpp @@ -722,6 +722,12 @@ const std::string& User::GetIPString() return cachedip; } +const std::string& User::GetBanIdent() const +{ + static const std::string wildcard = "*"; + return uniqueusername ? ident : wildcard; +} + const std::string& User::GetHost(bool uncloak) const { return uncloak ? GetRealHost() : GetDisplayedHost(); -- cgit v1.3.1-10-gc9f91