fix: Multiplayer network fixes and airplane mode

- Auto-select network interface for direct connect/host room
- Always recreate ENet client on join for fresh bindings
- Add airplane mode toggle (Desktop & Android)
- Fix JWT verification with empty verify_uid
- Improve content-type handling for JWT endpoints

Signed-off-by: Zephyron <zephyron@citron-emu.org>
This commit is contained in:
Zephyron
2025-11-10 17:16:45 +10:00
parent 2943eebc9c
commit be5c2f772c
16 changed files with 129 additions and 15 deletions

View File

@@ -188,7 +188,7 @@ void Lobby::OnJoinRoom(const QModelIndex& source) {
std::string token;
#ifdef ENABLE_WEB_SERVICE
if (!Settings::values.citron_username.GetValue().empty() &&
!Settings::values.citron_token.GetValue().empty()) {
!Settings::values.citron_token.GetValue().empty() && !verify_uid.empty()) {
WebService::Client client(Settings::values.web_api_url.GetValue(),
Settings::values.citron_username.GetValue(),
Settings::values.citron_token.GetValue());
@@ -198,6 +198,8 @@ void Lobby::OnJoinRoom(const QModelIndex& source) {
} else {
LOG_INFO(WebService, "Successfully requested external JWT: size={}", token.size());
}
} else if (verify_uid.empty()) {
LOG_DEBUG(WebService, "Skipping JWT request: verify_uid is empty (room may not require verification)");
}
#endif
if (auto room_member = room_network.GetRoomMember().lock()) {