diff options
author | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2005-12-04 15:02:00 +0000 |
---|---|---|
committer | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2005-12-04 15:02:00 +0000 |
commit | 491e012cfdd78f1a705d52ca42377a8a39634640 (patch) | |
tree | 5005b2c3a3a1fd254359f7bfa95d681cb8ef3578 | |
parent | 1817e4df761c5fb86473b7ce6aa341bc81077a72 (diff) |
Fixed usercounts to not screw up on remote users
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@2144 e03df62e-2008-0410-955e-edbf42e46eb7
-rw-r--r-- | src/helperfuncs.cpp | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/src/helperfuncs.cpp b/src/helperfuncs.cpp index cfb96cca2..ea7b1f9dc 100644 --- a/src/helperfuncs.cpp +++ b/src/helperfuncs.cpp @@ -1046,7 +1046,7 @@ int registered_usercount(void) int c = 0; for (user_hash::const_iterator i = clientlist.begin(); i != clientlist.end(); i++) { - if ((i->second->fd) && (isnick(i->second->nick))) c++; + if (i->second->registered == 7) c++; } return c; } @@ -1054,10 +1054,9 @@ int registered_usercount(void) int usercount_invisible(void) { int c = 0; - for (user_hash::const_iterator i = clientlist.begin(); i != clientlist.end(); i++) { - if ((i->second->fd) && (isnick(i->second->nick)) && (strchr(i->second->modes,'i'))) c++; + if ((isnick(i->second->nick)) && (strchr(i->second->modes,'i'))) c++; } return c; } @@ -1065,10 +1064,9 @@ int usercount_invisible(void) int usercount_opers(void) { int c = 0; - for (user_hash::const_iterator i = clientlist.begin(); i != clientlist.end(); i++) { - if ((i->second->fd) && (isnick(i->second->nick)) && (strchr(i->second->modes,'o'))) c++; + if ((isnick(i->second->nick)) && (strchr(i->second->modes,'o'))) c++; } return c; } |