diff options
author | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2006-10-28 18:12:45 +0000 |
---|---|---|
committer | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2006-10-28 18:12:45 +0000 |
commit | 034f74a23b3d6aff177682c916e18382621f495a (patch) | |
tree | 99840e8e12ee0da70c8e2acbb205a31d6e4cf3d9 /src/modules | |
parent | 73d36e20ed9f7ccdb6ce4e745a5eeed065f73bef (diff) |
Add support for OnWhoisLine, which allows modules to change or drop any line of whois before its sent to a user
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5570 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/modules')
-rw-r--r-- | src/modules/extra/m_ssl_gnutls.cpp | 2 | ||||
-rw-r--r-- | src/modules/extra/m_ssl_openssl.cpp | 2 | ||||
-rw-r--r-- | src/modules/m_botmode.cpp | 2 | ||||
-rw-r--r-- | src/modules/m_helpop.cpp | 2 | ||||
-rw-r--r-- | src/modules/m_services.cpp | 2 | ||||
-rw-r--r-- | src/modules/m_services_account.cpp | 2 | ||||
-rw-r--r-- | src/modules/m_ssl_dummy.cpp | 3 | ||||
-rw-r--r-- | src/modules/m_swhois.cpp | 2 |
8 files changed, 9 insertions, 8 deletions
diff --git a/src/modules/extra/m_ssl_gnutls.cpp b/src/modules/extra/m_ssl_gnutls.cpp index 049d3bfea..1d2e8561b 100644 --- a/src/modules/extra/m_ssl_gnutls.cpp +++ b/src/modules/extra/m_ssl_gnutls.cpp @@ -477,7 +477,7 @@ class ModuleSSLGnuTLS : public Module // Bugfix, only send this numeric for *our* SSL users if(dest->GetExt("ssl", dummy) || (IS_LOCAL(dest) && isin(dest->GetPort(), listenports))) { - source->WriteServ("320 %s %s :is using a secure connection", source->nick, dest->nick); + ServerInstance->SendWhoisLine(source, 320, "%s %s :is using a secure connection", source->nick, dest->nick); } } diff --git a/src/modules/extra/m_ssl_openssl.cpp b/src/modules/extra/m_ssl_openssl.cpp index 7f62bbfcb..905a9bf42 100644 --- a/src/modules/extra/m_ssl_openssl.cpp +++ b/src/modules/extra/m_ssl_openssl.cpp @@ -563,7 +563,7 @@ class ModuleSSLOpenSSL : public Module // Bugfix, only send this numeric for *our* SSL users if(dest->GetExt("ssl", dummy) || (IS_LOCAL(dest) && isin(dest->GetPort(), listenports))) { - source->WriteServ("320 %s %s :is using a secure connection", source->nick, dest->nick); + ServerInstance->SendWhoisLine(source, 320, "%s %s :is using a secure connection", source->nick, dest->nick); } } diff --git a/src/modules/m_botmode.cpp b/src/modules/m_botmode.cpp index 707a4e10c..4860ca55b 100644 --- a/src/modules/m_botmode.cpp +++ b/src/modules/m_botmode.cpp @@ -93,7 +93,7 @@ class ModuleBotMode : public Module { if (dst->IsModeSet('B')) { - src->WriteServ("335 "+std::string(src->nick)+" "+std::string(dst->nick)+" :is a \2bot\2 on "+ServerInstance->Config->Network); + ServerInstance->SendWhoisLine(src, 335, std::string(src->nick)+" "+std::string(dst->nick)+" :is a \2bot\2 on "+ServerInstance->Config->Network); } } diff --git a/src/modules/m_helpop.cpp b/src/modules/m_helpop.cpp index 3b1406368..8a69c422e 100644 --- a/src/modules/m_helpop.cpp +++ b/src/modules/m_helpop.cpp @@ -253,7 +253,7 @@ class ModuleHelpop : public Module { if (dst->IsModeSet('h')) { - src->WriteServ("310 "+std::string(src->nick)+" "+std::string(dst->nick)+" :is available for help."); + ServerInstance->SendWhoisLine(src, 310, std::string(src->nick)+" "+std::string(dst->nick)+" :is available for help."); } } diff --git a/src/modules/m_services.cpp b/src/modules/m_services.cpp index 1ae3c0992..b2797d72b 100644 --- a/src/modules/m_services.cpp +++ b/src/modules/m_services.cpp @@ -204,7 +204,7 @@ class ModuleServices : public Module if (dest->IsModeSet('r')) { /* user is registered */ - source->WriteServ("307 %s %s :is a registered nick", source->nick, dest->nick); + ServerInstance->SendWhoisLine(source, 307, "%s %s :is a registered nick", source->nick, dest->nick); } } diff --git a/src/modules/m_services_account.cpp b/src/modules/m_services_account.cpp index 651735e44..2e26d8fd5 100644 --- a/src/modules/m_services_account.cpp +++ b/src/modules/m_services_account.cpp @@ -140,7 +140,7 @@ class ModuleServicesAccount : public Module if (account) { - source->WriteServ("330 %s %s %s :is logged in as", source->nick, dest->nick, account->c_str()); + ServerInstance->SendWhoisLine(source, 330, "%s %s %s :is logged in as", source->nick, dest->nick, account->c_str()); } } diff --git a/src/modules/m_ssl_dummy.cpp b/src/modules/m_ssl_dummy.cpp index fadccae1e..c509e68cd 100644 --- a/src/modules/m_ssl_dummy.cpp +++ b/src/modules/m_ssl_dummy.cpp @@ -17,6 +17,7 @@ #include "users.h" #include "modules.h" +#include "inspircd.h" /* $ModDesc: Makes remote /whoises to SSL servers work on a non-ssl server */ @@ -51,7 +52,7 @@ class ModuleSSLDummy : public Module { if(dest->GetExt("ssl", dummy)) { - source->WriteServ("320 %s %s :is using a secure connection", source->nick, dest->nick); + ServerInstance->SendWhoisLine(source, 320, "%s %s :is using a secure connection", source->nick, dest->nick); } } diff --git a/src/modules/m_swhois.cpp b/src/modules/m_swhois.cpp index 849028dce..9d0cb70dc 100644 --- a/src/modules/m_swhois.cpp +++ b/src/modules/m_swhois.cpp @@ -110,7 +110,7 @@ class ModuleSWhois : public Module dest->GetExt("swhois", swhois); if (swhois) { - source->WriteServ("320 %s %s :%s",source->nick,dest->nick,swhois->c_str()); + ServerInstance->SendWhoisLine(source, 320, "%s %s :%s",source->nick,dest->nick,swhois->c_str()); } } |