diff options
-rw-r--r-- | include/bancache.h | 5 | ||||
-rw-r--r-- | src/bancache.cpp | 7 |
2 files changed, 8 insertions, 4 deletions
diff --git a/include/bancache.h b/include/bancache.h index e39a26d64..6e19e1ebe 100644 --- a/include/bancache.h +++ b/include/bancache.h @@ -40,10 +40,7 @@ class CoreExport BanCacheHit */ time_t Expiry; - BanCacheHit(const std::string &type, const std::string &reason, time_t seconds) - : Type(type), Reason(reason), Expiry(ServerInstance->Time() + seconds) - { - } + BanCacheHit(const std::string& type, const std::string& reason, time_t seconds); bool IsPositive() const { return (!Reason.empty()); } }; diff --git a/src/bancache.cpp b/src/bancache.cpp index a49454381..452bd998f 100644 --- a/src/bancache.cpp +++ b/src/bancache.cpp @@ -21,6 +21,13 @@ #include "inspircd.h" #include "bancache.h" +BanCacheHit::BanCacheHit(const std::string& type, const std::string& reason, time_t seconds) + : Type(type) + , Reason(reason) + , Expiry(ServerInstance->Time() + seconds) +{ +} + BanCacheHit *BanCacheManager::AddHit(const std::string &ip, const std::string &type, const std::string &reason, time_t seconds) { BanCacheHit*& b = BanHash[ip]; |