diff options
author | ouwou <26526779+ouwou@users.noreply.github.com> | 2020-12-15 01:51:49 -0500 |
---|---|---|
committer | ouwou <26526779+ouwou@users.noreply.github.com> | 2020-12-15 01:51:49 -0500 |
commit | 2667a4b30dd346f70aa8ca1ee7994c559be6d2bb (patch) | |
tree | 0ff7113d5c30e465e83a330fc1f19bd803bcc68d /discord/user.cpp | |
parent | 0c313ce5e8e849bcbaf23fcdf86f31ea38475d0e (diff) | |
download | abaddon-portaudio-2667a4b30dd346f70aa8ca1ee7994c559be6d2bb.tar.gz abaddon-portaudio-2667a4b30dd346f70aa8ca1ee7994c559be6d2bb.zip |
display reactions + click to add/remove
Diffstat (limited to 'discord/user.cpp')
-rw-r--r-- | discord/user.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/discord/user.cpp b/discord/user.cpp index 78d309b..56f0350 100644 --- a/discord/user.cpp +++ b/discord/user.cpp @@ -33,6 +33,13 @@ void from_json(const nlohmann::json &j, User &m) { JS_ON("phone", m.Phone); } +void to_json(nlohmann::json &j, const User &m) { + j["id"] = m.ID; + j["username"] = m.Username; + j["avatar"] = m.Avatar; + // rest of stuff as needed im too lazy and its probably not necessary +} + void User::update_from_json(const nlohmann::json &j, User &m) { JS_RD("username", m.Username); JS_RD("discriminator", m.Discriminator); |