add ability to reorder roles

- some other small tweaks
This commit is contained in:
ouwou
2021-03-12 01:55:46 -05:00
parent f35dea89f9
commit ae38add931
10 changed files with 313 additions and 19 deletions

View File

@@ -526,3 +526,15 @@ struct ModifyGuildRoleObject {
friend void to_json(nlohmann::json &j, const ModifyGuildRoleObject &m);
};
struct ModifyGuildRolePositionsObject {
struct PositionParam {
Snowflake ID;
std::optional<int> Position; // no idea why this can be optional
friend void to_json(nlohmann::json &j, const PositionParam &m);
};
std::vector<PositionParam> Positions;
friend void to_json(nlohmann::json &j, const ModifyGuildRolePositionsObject &m);
};