diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/nickalias.cpp | 6 | ||||
-rw-r--r-- | src/nickcore.cpp | 7 | ||||
-rw-r--r-- | src/regchannel.cpp | 8 |
3 files changed, 13 insertions, 8 deletions
diff --git a/src/nickalias.cpp b/src/nickalias.cpp index 95deca85f..989e02895 100644 --- a/src/nickalias.cpp +++ b/src/nickalias.cpp @@ -226,16 +226,18 @@ Serializable *NickAlias::Type::Unserialize(Serializable *obj, Serialize::Data &d Extensible::ExtensibleUnserialize(na, na, data); - /* compat */ + // Begin 1.9 compatibility. bool b; b = false; data["extensible:NO_EXPIRE"] >> b; if (b) na->Extend<bool>("NS_NO_EXPIRE"); + // End 1.9 compatibility. + // Begin 2.0 compatibility. if (na->registered < na->nc->registered) na->nc->registered = na->registered; - /* end compat */ + // End 2.0 compatibility. return na; } diff --git a/src/nickcore.cpp b/src/nickcore.cpp index b1b43d533..c39a43764 100644 --- a/src/nickcore.cpp +++ b/src/nickcore.cpp @@ -123,7 +123,7 @@ Serializable *NickCore::Type::Unserialize(Serializable *obj, Serialize::Data &da Extensible::ExtensibleUnserialize(nc, nc, data); - /* compat */ + // Begin 1.9 compatibility. bool b; b = false; data["extensible:PRIVATE"] >> b; @@ -153,7 +153,10 @@ Serializable *NickCore::Type::Unserialize(Serializable *obj, Serialize::Data &da data["extensible:KILLPROTECT"] >> b; if (b) nc->Extend<bool>("PROTECT"); + // End 1.9 compatibility + + // Begin 2.0 compatibility. b = false; data["KILLPROTECT"] >> b; if (b) @@ -175,7 +178,7 @@ Serializable *NickCore::Type::Unserialize(Serializable *obj, Serialize::Data &da nc->Extend<bool>("PROTECT"); nc->Extend("PROTECT_AFTER", 0); } - /* end compat */ + // End 2.0 compatibility. return nc; } diff --git a/src/regchannel.cpp b/src/regchannel.cpp index eb05722eb..861ff2af1 100644 --- a/src/regchannel.cpp +++ b/src/regchannel.cpp @@ -255,10 +255,10 @@ Serializable *ChannelInfo::Type::Unserialize(Serializable *obj, Serialize::Data spacesepstream(slevels).GetTokens(v); for (unsigned i = 0; i + 1 < v.size(); i += 2) { - // Begin 2.0 database compatibility. + // Begin 2.0 compatibility. if (v[i] == "FANTASIA") v[i] = "FANTASY"; - // End 2.0 database compatibility. + // End 2.0 compatibility. if (auto level = Anope::TryConvert<int16_t>(v[i + 1])) ci->levels[v[i]] = level.value(); } @@ -284,7 +284,7 @@ Serializable *ChannelInfo::Type::Unserialize(Serializable *obj, Serialize::Data Extensible::ExtensibleUnserialize(ci, ci, data); - /* compat */ + // Begin 1.9 compatibility. bool b; b = false; data["extensible:PRIVATE"] >> b; @@ -326,7 +326,7 @@ Serializable *ChannelInfo::Type::Unserialize(Serializable *obj, Serialize::Data data["extensible:SIGNKICK_LEVEL"] >> b; if (b) ci->Extend<bool>("SIGNKICK_LEVEL"); - /* end compat */ + // End 1.9 compatibility. return ci; } |