summaryrefslogtreecommitdiff
path: root/modules/commands/cs_seen.cpp
diff options
context:
space:
mode:
authorAdam <Adam@anope.org>2011-11-08 17:29:16 -0500
committerAdam <Adam@anope.org>2011-11-08 17:29:16 -0500
commitb5ff856f47d8e54d12c568462a06351633c29610 (patch)
treea4e2f96c59ee49aa5e6cacdfd30db6155151ad36 /modules/commands/cs_seen.cpp
parent97b9055f92f21cd91af44a3d5dacce0024536cff (diff)
Windows
Diffstat (limited to 'modules/commands/cs_seen.cpp')
-rw-r--r--modules/commands/cs_seen.cpp11
1 files changed, 7 insertions, 4 deletions
diff --git a/modules/commands/cs_seen.cpp b/modules/commands/cs_seen.cpp
index f828e181d..3c63e56ed 100644
--- a/modules/commands/cs_seen.cpp
+++ b/modules/commands/cs_seen.cpp
@@ -23,7 +23,7 @@ struct SeenInfo;
typedef Anope::insensitive_map<SeenInfo *> database_map;
database_map database;
-struct SeenInfo : Serializable<SeenInfo>
+struct SeenInfo : Serializable
{
Anope::string nick;
Anope::string vhost;
@@ -33,6 +33,10 @@ struct SeenInfo : Serializable<SeenInfo>
Anope::string message; // for part/kick/quit
time_t last; // the time when the user was last seen
+ SeenInfo() : Serializable("SeenInfo")
+ {
+ }
+
serialized_data serialize()
{
serialized_data data;
@@ -304,11 +308,12 @@ class DataBasePurger : public CallBack
class CSSeen : public Module
{
+ SerializeType seeninfo_type;
CommandSeen commandseen;
CommandOSSeen commandosseen;
DataBasePurger purger;
public:
- CSSeen(const Anope::string &modname, const Anope::string &creator) : Module(modname, creator, CORE), commandseen(this), commandosseen(this), purger(this)
+ CSSeen(const Anope::string &modname, const Anope::string &creator) : Module(modname, creator, CORE), seeninfo_type("SeenInfo", SeenInfo::unserialize), commandseen(this), commandosseen(this), purger(this)
{
this->SetAuthor("Anope");
@@ -322,8 +327,6 @@ class CSSeen : public Module
ModuleManager::Attach(eventlist, this, sizeof(eventlist)/sizeof(Implementation));
OnReload();
-
- Serializable<SeenInfo>::Alloc.Register("SeenInfo");
}
void OnReload()