mirror of
https://github.com/yuzu-emu/discord-rpc
synced 2024-11-26 01:07:55 +00:00
partyMax is mandatory if partySize is included (#122)
This commit is contained in:
parent
c4201806cf
commit
453222075b
1 changed files with 2 additions and 4 deletions
|
@ -138,14 +138,12 @@ size_t JsonWriteRichPresenceObj(char* dest,
|
||||||
presence->partyMax) {
|
presence->partyMax) {
|
||||||
WriteObject party(writer, "party");
|
WriteObject party(writer, "party");
|
||||||
WriteOptionalString(writer, "id", presence->partyId);
|
WriteOptionalString(writer, "id", presence->partyId);
|
||||||
if (presence->partySize) {
|
if (presence->partySize && presence->partyMax) {
|
||||||
WriteArray size(writer, "size");
|
WriteArray size(writer, "size");
|
||||||
writer.Int(presence->partySize);
|
writer.Int(presence->partySize);
|
||||||
if (0 < presence->partyMax) {
|
|
||||||
writer.Int(presence->partyMax);
|
writer.Int(presence->partyMax);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
if ((presence->matchSecret && presence->matchSecret[0]) ||
|
if ((presence->matchSecret && presence->matchSecret[0]) ||
|
||||||
(presence->joinSecret && presence->joinSecret[0]) ||
|
(presence->joinSecret && presence->joinSecret[0]) ||
|
||||||
|
|
Loading…
Reference in a new issue