summaryrefslogtreecommitdiff
path: root/src/base.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/base.cpp')
-rw-r--r--src/base.cpp8
1 files changed, 2 insertions, 6 deletions
diff --git a/src/base.cpp b/src/base.cpp
index 316cd17c5..db32647ad 100644
--- a/src/base.cpp
+++ b/src/base.cpp
@@ -13,16 +13,12 @@
std::map<Anope::string, std::map<Anope::string, Service *> > Service::Services;
std::map<Anope::string, std::map<Anope::string, Anope::string> > Service::Aliases;
-Base::Base() : references(NULL)
-{
-}
-
Base::~Base()
{
if (this->references != NULL)
{
- for (std::set<ReferenceBase *>::iterator it = this->references->begin(), it_end = this->references->end(); it != it_end; ++it)
- (*it)->Invalidate();
+ for (auto *reference : *this->references)
+ reference->Invalidate();
delete this->references;
}
}