diff options
author | Adam <Adam@anope.org> | 2016-12-01 09:25:53 -0500 |
---|---|---|
committer | Adam <Adam@anope.org> | 2016-12-01 09:25:53 -0500 |
commit | ca28f9cfcbff0fbdb2afe96f1427245f83db7c47 (patch) | |
tree | ac5de801a4db01a7cb689ec670537ad74c7c53e6 /modules/botserv/badwords.cpp | |
parent | 2f512281029fbf4f7ef9832e05804831ad2d9ba2 (diff) |
Allow objects to opt out of gc, don't gc accounts with users logged in
Also store cached state with the field by using Serialize::Storage for
field storage
Diffstat (limited to 'modules/botserv/badwords.cpp')
-rw-r--r-- | modules/botserv/badwords.cpp | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/modules/botserv/badwords.cpp b/modules/botserv/badwords.cpp index 914e89ea9..754e202a7 100644 --- a/modules/botserv/badwords.cpp +++ b/modules/botserv/badwords.cpp @@ -24,13 +24,12 @@ class BadWordImpl : public BadWord { friend class BadWordsType; - ChanServ::Channel *channel = nullptr; - Anope::string word; - BadWordType type; + Serialize::Storage<ChanServ::Channel *> channel; + Serialize::Storage<Anope::string> word; + Serialize::Storage<BadWordType> type; public: - BadWordImpl(Serialize::TypeBase *type) : BadWord(type) { } - BadWordImpl(Serialize::TypeBase *type, Serialize::ID id) : BadWord(type, id) { } + using BadWord::BadWord; ChanServ::Channel *GetChannel() override; void SetChannel(ChanServ::Channel *c) override; |