diff options
author | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2007-05-09 21:26:12 +0000 |
---|---|---|
committer | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2007-05-09 21:26:12 +0000 |
commit | 832e4d6003d48a07a727921fcbaf13ea777356b2 (patch) | |
tree | fc9e75972e2a2f5a7fc6f39f4a82fc07218312a1 | |
parent | d0bde383434a9a88fc2737da8f8ca92e98d4c967 (diff) |
If we're having local, we need far too (f)
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6929 e03df62e-2008-0410-955e-edbf42e46eb7
-rw-r--r-- | include/commands/cmd_who.h | 3 | ||||
-rw-r--r-- | src/cmd_who.cpp | 6 |
2 files changed, 8 insertions, 1 deletions
diff --git a/include/commands/cmd_who.h b/include/commands/cmd_who.h index bc1601358..7e1d8affe 100644 --- a/include/commands/cmd_who.h +++ b/include/commands/cmd_who.h @@ -37,8 +37,9 @@ class cmd_who : public command_t bool opt_port; bool opt_away; bool opt_local; + bool opt_far; public: - cmd_who (InspIRCd* Instance) : command_t(Instance,"WHO",0,1) { syntax = "<server>|<nickname>|<channel>|<realname>|<host>|0 [ohurmMiapl]"; } + cmd_who (InspIRCd* Instance) : command_t(Instance,"WHO",0,1) { syntax = "<server>|<nickname>|<channel>|<realname>|<host>|0 [ohurmMiaplf]"; } void SendWhoLine(userrec* user, const std::string &initial, chanrec* ch, userrec* u, std::vector<std::string> &whoresults); CmdResult Handle(const char** parameters, int pcnt, userrec *user); bool whomatch(userrec* user, const char* matchtext); diff --git a/src/cmd_who.cpp b/src/cmd_who.cpp index 097059498..5992d7aa0 100644 --- a/src/cmd_who.cpp +++ b/src/cmd_who.cpp @@ -46,6 +46,8 @@ bool cmd_who::whomatch(userrec* user, const char* matchtext) if (opt_local && !IS_LOCAL(user)) return false; + else if (opt_far && IS_LOCAL(user)) + return false; if (opt_mode) { @@ -178,6 +180,7 @@ CmdResult cmd_who::Handle (const char** parameters, int pcnt, userrec *user) opt_port = false; opt_away = false; opt_local = false; + opt_far = false; chanrec *ch = NULL; std::vector<std::string> whoresults; @@ -231,6 +234,9 @@ CmdResult cmd_who::Handle (const char** parameters, int pcnt, userrec *user) case 'l': opt_local = true; break; + case 'f': + opt_far = true; + break; } *iter++; |