diff options
author | Attila Molnar <attilamolnar@hush.com> | 2015-12-05 15:02:20 +0100 |
---|---|---|
committer | Attila Molnar <attilamolnar@hush.com> | 2015-12-05 15:02:20 +0100 |
commit | 806f48627913db210be7c9104de5afe2f47bdb33 (patch) | |
tree | f1d394961571213d18a681d25f360f139bd31538 /src | |
parent | 0528e83604da80d87ae10f85841a5a9e33274f71 (diff) |
m_ircv3 Change signature of WriteNeighboursWithExt to accept a cap, rename
Diffstat (limited to 'src')
-rw-r--r-- | src/modules/m_ircv3.cpp | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/src/modules/m_ircv3.cpp b/src/modules/m_ircv3.cpp index caee0d329..123d07069 100644 --- a/src/modules/m_ircv3.cpp +++ b/src/modules/m_ircv3.cpp @@ -20,20 +20,20 @@ #include "modules/account.h" #include "modules/cap.h" -class WriteNeighboursWithExt : public User::ForEachNeighborHandler +class WriteNeighborsWithCap : public User::ForEachNeighborHandler { - const LocalIntExt& ext; + const LocalIntExt& cap; const std::string& msg; void Execute(LocalUser* user) CXX11_OVERRIDE { - if (ext.get(user)) + if (cap.get(user)) user->Write(msg); } public: - WriteNeighboursWithExt(User* user, const std::string& message, const LocalIntExt& extension) - : ext(extension) + WriteNeighborsWithCap(User* user, const std::string& message, const GenericCap& capability) + : cap(capability.ext) , msg(message) { user->ForEachNeighbor(*this, false); @@ -76,7 +76,7 @@ class ModuleIRCv3 : public Module, public AccountEventListener else line += newaccount; - WriteNeighboursWithExt(user, line, cap_accountnotify.ext); + WriteNeighborsWithCap(user, line, cap_accountnotify); } void OnUserJoin(Membership* memb, bool sync, bool created, CUList& excepts) CXX11_OVERRIDE @@ -162,7 +162,7 @@ class ModuleIRCv3 : public Module, public AccountEventListener if (!awaymsg.empty()) line += " :" + awaymsg; - WriteNeighboursWithExt(user, line, cap_awaynotify.ext); + WriteNeighborsWithCap(user, line, cap_awaynotify); } return MOD_RES_PASSTHRU; } |