diff options
author | Naram Qashat <cyberbotx@cyberbotx.com> | 2010-07-30 13:15:35 -0400 |
---|---|---|
committer | Naram Qashat <cyberbotx@cyberbotx.com> | 2010-07-30 13:15:35 -0400 |
commit | 174cc58a8d5f956ecebdc4ee90ed3cd115b78afa (patch) | |
tree | cee5f0aa8fd778c04065e3fc6fdc6a1ded71d3fa /src/nickcore.cpp | |
parent | 527304ed2cbe0e217c4c5cd35716b4f5f44d8431 (diff) |
Slight code cleanup in nickalias.cpp and nickcore.cpp.
Diffstat (limited to 'src/nickcore.cpp')
-rw-r--r-- | src/nickcore.cpp | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/src/nickcore.cpp b/src/nickcore.cpp index a3b97a6e7..6f9ff99c9 100644 --- a/src/nickcore.cpp +++ b/src/nickcore.cpp @@ -9,16 +9,16 @@ NickCore::NickCore(const Anope::string &coredisplay) if (coredisplay.empty()) throw CoreException("Empty display passed to NickCore constructor"); - ot = NULL; - language = channelcount = 0; - lastmail = 0; + this->ot = NULL; + this->language = this->channelcount = 0; + this->lastmail = 0; this->display = coredisplay; /* Set default nick core flags */ for (size_t t = NI_BEGIN + 1; t != NI_END; ++t) if (Config.NSDefFlags.HasFlag(static_cast<NickCoreFlag>(t))) - SetFlag(static_cast<NickCoreFlag>(t)); + this->SetFlag(static_cast<NickCoreFlag>(t)); NickCoreList[this->display] = this; } @@ -91,21 +91,21 @@ bool NickCore::HasPriv(const Anope::string &privstr) const void NickCore::AddAccess(const Anope::string &entry) { - access.push_back(entry); + this->access.push_back(entry); FOREACH_MOD(I_OnNickAddAccess, OnNickAddAccess(this, entry)); } Anope::string NickCore::GetAccess(unsigned entry) const { - if (access.empty() || entry >= access.size()) + if (this->access.empty() || entry >= this->access.size()) return ""; - return access[entry]; + return this->access[entry]; } bool NickCore::FindAccess(const Anope::string &entry) { - for (unsigned i = 0, end = access.size(); i < end; ++i) - if (access[i] == entry) + for (unsigned i = 0, end = this->access.size(); i < end; ++i) + if (this->access[i] == entry) return true; return false; @@ -113,11 +113,11 @@ bool NickCore::FindAccess(const Anope::string &entry) void NickCore::EraseAccess(const Anope::string &entry) { - for (unsigned i = 0, end = access.size(); i < end; ++i) - if (access[i] == entry) + for (unsigned i = 0, end = this->access.size(); i < end; ++i) + if (this->access[i] == entry) { FOREACH_MOD(I_OnNickEraseAccess, OnNickEraseAccess(this, entry)); - access.erase(access.begin() + i); + this->access.erase(this->access.begin() + i); break; } } @@ -125,5 +125,5 @@ void NickCore::EraseAccess(const Anope::string &entry) void NickCore::ClearAccess() { FOREACH_MOD(I_OnNickClearAccess, OnNickClearAccess(this)); - access.clear(); + this->access.clear(); } |