From fd1d19d6345943ecdb5ce4ef947f9b3c5c8bca86 Mon Sep 17 00:00:00 2001 From: attilamolnar Date: Tue, 18 Jun 2013 19:10:07 +0200 Subject: Replace hardcoded mode letters, part 3 This changes most remaining User::IsModeSet() calls to use ModeReferences for modes that were created by other modules or the core --- src/channels.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/channels.cpp') diff --git a/src/channels.cpp b/src/channels.cpp index 505ef479a..e9e2a3020 100644 --- a/src/channels.cpp +++ b/src/channels.cpp @@ -36,6 +36,7 @@ namespace ChanModeReference limitmode(NULL, "limit"); ChanModeReference secretmode(NULL, "secret"); ChanModeReference privatemode(NULL, "private"); + UserModeReference invisiblemode(NULL, "invisible"); } Channel::Channel(const std::string &cname, time_t ts) @@ -683,7 +684,7 @@ void Channel::UserList(User *user) { if (i->first->quitting) continue; - if ((!has_user) && (i->first->IsModeSet('i'))) + if ((!has_user) && (i->first->IsModeSet(invisiblemode))) { /* * user is +i, and source not on the channel, does not show -- cgit v1.3.1-10-gc9f91