Skip to content

Commit

Permalink
fix: bugfix and tweak
Browse files Browse the repository at this point in the history
  • Loading branch information
braindigitalis committed Oct 2, 2023
1 parent 85f2802 commit 7967239
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/dpp/guild.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -241,18 +241,18 @@ std::string guild_member::build_json(bool with_id) const {
}
}

if (this->flags & gm_nickname_action) {
if (gm_nickname_action) {
if (!this->nickname.empty()) {
j["nick"] = this->nickname;
} else {
j["nick"] = json::value_t::null;
}
}

if (this->flags & gm_roles_action) {
if (gm_roles_action) {
if (!this->roles.empty()) {
j["roles"] = {};
for (auto & role : this->roles) {
for (const auto & role : this->roles) {
j["roles"].push_back(std::to_string(role));
}
} else {
Expand Down

0 comments on commit 7967239

Please sign in to comment.