network, citra_qt: Give moderation permission to community mods
Based on the `roles` payload in the JWT, the rooms will now give mod permission to Citra Community Moderators. To notify the client of its permissions, a new response, IdJoinSuccessAsMod is added, and there's now a new RoomMember::State called Moderator.
This commit is contained in:
parent
94be4050bc
commit
9d062d63da
15 changed files with 73 additions and 27 deletions
|
@ -59,7 +59,8 @@ public:
|
|||
Uninitialized, ///< Not initialized
|
||||
Idle, ///< Default state (i.e. not connected)
|
||||
Joining, ///< The client is attempting to join a room.
|
||||
Joined, ///< The client is connected to the room and is ready to send/receive packets.
|
||||
Joined, ///< The client is connected to the room and is ready to send/receive packets.
|
||||
Moderator, ///< The client is connnected to the room and is granted mod permissions.
|
||||
};
|
||||
|
||||
enum class Error : u8 {
|
||||
|
@ -270,6 +271,8 @@ static const char* GetStateStr(const RoomMember::State& s) {
|
|||
return "Joining";
|
||||
case RoomMember::State::Joined:
|
||||
return "Joined";
|
||||
case RoomMember::State::Moderator:
|
||||
return "Moderator";
|
||||
}
|
||||
return "Unknown";
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue