diff options
author | Sadie Powell <sadie@witchery.services> | 2024-03-15 12:42:13 +0000 |
---|---|---|
committer | Sadie Powell <sadie@witchery.services> | 2024-03-15 12:42:13 +0000 |
commit | 753119c4a16f6dafacbeb3d98fe72133badca949 (patch) | |
tree | ac57504794ae2ff44a98207c77ef087d9a2a4c38 /src | |
parent | d996c3aa8fccb032332aa8e2ea12d07127cae969 (diff) |
Use consistent casing when referring to vhosts and vidents.
Diffstat (limited to 'src')
-rw-r--r-- | src/nickalias.cpp | 34 | ||||
-rw-r--r-- | src/users.cpp | 4 |
2 files changed, 19 insertions, 19 deletions
diff --git a/src/nickalias.cpp b/src/nickalias.cpp index cfd59094d..edd38a23c 100644 --- a/src/nickalias.cpp +++ b/src/nickalias.cpp @@ -76,7 +76,7 @@ NickAlias::~NickAlias() NickAliasList->erase(this->nick); } -void NickAlias::SetVhost(const Anope::string &ident, const Anope::string &host, const Anope::string &creator, time_t created) +void NickAlias::SetVHost(const Anope::string &ident, const Anope::string &host, const Anope::string &creator, time_t created) { this->vhost_ident = ident; this->vhost_host = host; @@ -84,7 +84,7 @@ void NickAlias::SetVhost(const Anope::string &ident, const Anope::string &host, this->vhost_created = created; } -void NickAlias::RemoveVhost() +void NickAlias::RemoveVHost() { this->vhost_ident.clear(); this->vhost_host.clear(); @@ -92,35 +92,35 @@ void NickAlias::RemoveVhost() this->vhost_created = 0; } -bool NickAlias::HasVhost() const +bool NickAlias::HasVHost() const { return !this->vhost_host.empty(); } -const Anope::string &NickAlias::GetVhostIdent() const +const Anope::string &NickAlias::GetVHostIdent() const { return this->vhost_ident; } -const Anope::string &NickAlias::GetVhostHost() const +const Anope::string &NickAlias::GetVHostHost() const { return this->vhost_host; } -Anope::string NickAlias::GetVhostMask() const +Anope::string NickAlias::GetVHostMask() const { - if (this->GetVhostIdent().empty()) - return this->GetVhostHost(); + if (this->GetVHostIdent().empty()) + return this->GetVHostHost(); - return this->GetVhostIdent() + "@" + this->GetVhostHost(); + return this->GetVHostIdent() + "@" + this->GetVHostHost(); } -const Anope::string &NickAlias::GetVhostCreator() const +const Anope::string &NickAlias::GetVHostCreator() const { return this->vhost_creator; } -time_t NickAlias::GetVhostCreated() const +time_t NickAlias::GetVHostCreated() const { return this->vhost_created; } @@ -148,12 +148,12 @@ void NickAlias::Serialize(Serialize::Data &data) const data.SetType("last_seen", Serialize::Data::DT_INT); data["last_seen"] << this->last_seen; data["nc"] << this->nc->display; - if (this->HasVhost()) + if (this->HasVHost()) { - data["vhost_ident"] << this->GetVhostIdent(); - data["vhost_host"] << this->GetVhostHost(); - data["vhost_creator"] << this->GetVhostCreator(); - data["vhost_time"] << this->GetVhostCreated(); + data["vhost_ident"] << this->GetVHostIdent(); + data["vhost_host"] << this->GetVHostHost(); + data["vhost_creator"] << this->GetVHostCreator(); + data["vhost_time"] << this->GetVHostCreated(); } Extensible::ExtensibleSerialize(this, this, data); @@ -206,7 +206,7 @@ Serializable *NickAlias::Unserialize(Serializable *obj, Serialize::Data &data) data["vhost_creator"] >> vhost_creator; data["vhost_time"] >> vhost_time; - na->SetVhost(vhost_ident, vhost_host, vhost_creator, vhost_time); + na->SetVHost(vhost_ident, vhost_host, vhost_creator, vhost_time); Extensible::ExtensibleUnserialize(na, na, data); diff --git a/src/users.cpp b/src/users.cpp index 0fc8d2dd9..c0e516df9 100644 --- a/src/users.cpp +++ b/src/users.cpp @@ -388,7 +388,7 @@ void User::Identify(NickAlias *na) { this->SendMessage(NULL, "Changing your vhost to \002%s\002", this->nc->o->vhost.c_str()); this->SetDisplayedHost(this->nc->o->vhost); - IRCD->SendVhost(this, "", this->nc->o->vhost); + IRCD->SendVHost(this, "", this->nc->o->vhost); } } } @@ -553,7 +553,7 @@ void User::SetModeInternal(const MessageSource &source, UserMode *um, const Anop { this->SendMessage(NULL, "Changing your vhost to \002%s\002", this->nc->o->vhost.c_str()); this->SetDisplayedHost(this->nc->o->vhost); - IRCD->SendVhost(this, "", this->nc->o->vhost); + IRCD->SendVHost(this, "", this->nc->o->vhost); } } } |