diff options
author | Sadie Powell <sadie@witchery.services> | 2025-05-03 17:07:07 +0100 |
---|---|---|
committer | Sadie Powell <sadie@witchery.services> | 2025-05-03 21:28:56 +0100 |
commit | 010beb52b1f3c697a07f9a130d2ed9335fe1cd98 (patch) | |
tree | 734750a5677afff443f2117dc34ba14d3351fb28 /include/channels.h | |
parent | c95594141346ef6fb65a5af177bed35ed865234d (diff) |
Store the setter and ts for all modes and try to restore them.
This is mostly for preserving channel list mode info.
Diffstat (limited to 'include/channels.h')
-rw-r--r-- | include/channels.h | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/include/channels.h b/include/channels.h index 9d1c5b738..155feadb2 100644 --- a/include/channels.h +++ b/include/channels.h @@ -36,7 +36,7 @@ class CoreExport Channel final static std::vector<Channel *> deleting; public: - typedef std::multimap<Anope::string, Anope::string> ModeList; + typedef std::multimap<Anope::string, ModeData> ModeList; private: /** A map of channel modes with their parameters set on this channel */ @@ -148,10 +148,10 @@ public: /** Set a mode internally on a channel, this is not sent out to the IRCd * @param setter The setter * @param cm The mode - * @param param The param + * @param data Data about the mode. * @param enforce_mlock true if mlocks should be enforced, false to override mlock */ - void SetModeInternal(MessageSource &source, ChannelMode *cm, const Anope::string ¶m = "", bool enforce_mlock = true); + void SetModeInternal(MessageSource &source, ChannelMode *cm, const ModeData &data = {}, bool enforce_mlock = true); /** Remove a mode internally on a channel, this is not sent out to the IRCd * @param setter The Setter @@ -164,19 +164,19 @@ public: /** Set a mode on a channel * @param bi The client setting the modes * @param cm The mode - * @param param Optional param arg for the mode + * @param data Data about the mode * @param enforce_mlock true if mlocks should be enforced, false to override mlock */ - void SetMode(BotInfo *bi, ChannelMode *cm, const Anope::string ¶m = "", bool enforce_mlock = true); + void SetMode(BotInfo *bi, ChannelMode *cm, const ModeData &data = {}, bool enforce_mlock = true); /** * Set a mode on a channel * @param bi The client setting the modes * @param name The mode name - * @param param Optional param arg for the mode + * @param data Data about the mode * @param enforce_mlock true if mlocks should be enforced, false to override mlock */ - void SetMode(BotInfo *bi, const Anope::string &name, const Anope::string ¶m = "", bool enforce_mlock = true); + void SetMode(BotInfo *bi, const Anope::string &name, const ModeData &data = {}, bool enforce_mlock = true); /** Remove a mode from a channel * @param bi The client setting the modes |