summaryrefslogtreecommitdiffstats
path: root/src/ClientInfo.hpp
diff options
context:
space:
mode:
authorMarkus Mittendrein <git@maxmitti.tk>2016-08-14 21:29:27 +0200
committerMarkus Mittendrein <git@maxmitti.tk>2016-08-14 21:29:27 +0200
commitea9ae80dc2dbad15c2a6e9cde49d8322ce6f3f4f (patch)
treee1d3e1e4716eb333b258d13ba939dcbf2d7af8bb /src/ClientInfo.hpp
parent99eeb53fcb714d3028f1ddf8c3343c114920fa38 (diff)
downloadmanager-ea9ae80dc2dbad15c2a6e9cde49d8322ce6f3f4f.tar.gz
manager-ea9ae80dc2dbad15c2a6e9cde49d8322ce6f3f4f.zip
Handle IRC-Nicks case-insensitively
Diffstat (limited to 'src/ClientInfo.hpp')
-rw-r--r--src/ClientInfo.hpp13
1 files changed, 12 insertions, 1 deletions
diff --git a/src/ClientInfo.hpp b/src/ClientInfo.hpp
index 4a4ef0b..d176965 100644
--- a/src/ClientInfo.hpp
+++ b/src/ClientInfo.hpp
@@ -82,7 +82,18 @@ public:
inline bool operator==(const ClientInfo& other) const
{
- return other.interface == interface && other.nick == nick && (interface == Clonk ? other.pcName == pcName && other.CUID == CUID : true);
+ if(other.interface != interface)
+ {
+ return false;
+ }
+ if(interface == IRC)
+ {
+ return other.nick.compare(nick, Qt::CaseInsensitive) == 0;
+ }
+ else
+ {
+ return other.interface == interface && other.nick == nick && (interface == Clonk ? other.pcName == pcName && other.CUID == CUID : true);
+ }
}
inline bool operator!=(const ClientInfo& other) const