1
0
mirror of https://github.com/ppy/osu.git synced 2024-11-11 14:17:26 +08:00

Fix request failing due to parameters

This commit is contained in:
smoogipoo 2021-07-19 21:24:22 +09:00
parent a001e4aa16
commit 0a43e54dfc

View File

@ -22,13 +22,10 @@ namespace osu.Game.Online.Rooms
{
var req = base.CreateWebRequest();
req.Method = HttpMethod.Put;
if (!string.IsNullOrEmpty(Password))
req.AddParameter("password", Password);
return req;
}
protected override string Target => $"rooms/{Room.RoomID.Value}/users/{User.Id}";
// Todo: Password needs to be specified here rather than via AddParameter() because this is a PUT request. May be a framework bug.
protected override string Target => $"rooms/{Room.RoomID.Value}/users/{User.Id}?password={Password}";
}
}