diff options
| author | 2007-05-04 14:52:31 +0000 | |
|---|---|---|
| committer | 2007-05-04 14:52:31 +0000 | |
| commit | 36fe193886fcf3d583e259018f82c2f217c05a39 (patch) | |
| tree | 62600ce84842dc4731f6f53f9c5b6dbdbb4bad23 /src/cmd_who.cpp | |
| parent | Apply visibility state to whois, next stop, /who (diff) | |
| download | inspircd++-36fe193886fcf3d583e259018f82c2f217c05a39.tar.gz inspircd++-36fe193886fcf3d583e259018f82c2f217c05a39.tar.bz2 inspircd++-36fe193886fcf3d583e259018f82c2f217c05a39.zip | |
Fix /who to hide users marked invisibile in some way by a module
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6870 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/cmd_who.cpp')
| -rw-r--r-- | src/cmd_who.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/cmd_who.cpp b/src/cmd_who.cpp index c6a6a33c7..dfd0a445a 100644 --- a/src/cmd_who.cpp +++ b/src/cmd_who.cpp @@ -96,6 +96,10 @@ void cmd_who::SendWhoLine(userrec* user, const std::string &initial, chanrec* ch std::string lcn = getlastchanname(u); chanrec* chlast = ServerInstance->FindChan(lcn); + /* Not visible to this user */ + if (u->Visibility && !u->Visibility->VisibleTo(user)) + return; + std::string wholine = initial + (ch ? ch->name : lcn) + " " + u->ident + " " + (opt_showrealhost ? u->host : u->dhost) + " " + ((*ServerInstance->Config->HideWhoisServer && !*user->oper) ? ServerInstance->Config->HideWhoisServer : u->server) + " " + u->nick + " "; |
