Fix some web requests retrieving the user too early

This commit is contained in:
Dean Herbert
2020-07-14 13:07:17 +09:00
parent 8411a36a0f
commit 7fe69bb199
8 changed files with 22 additions and 28 deletions

View File

@ -381,7 +381,7 @@ namespace osu.Game.Online.Chat
break;
default:
var req = new JoinChannelRequest(channel, api.LocalUser.Value);
var req = new JoinChannelRequest(channel);
req.Success += () => joinChannel(channel, fetchInitialMessages);
req.Failure += ex => LeaveChannel(channel);
api.Queue(req);
@ -410,7 +410,7 @@ namespace osu.Game.Online.Chat
if (channel.Joined.Value)
{
api.Queue(new LeaveChannelRequest(channel, api.LocalUser.Value));
api.Queue(new LeaveChannelRequest(channel));
channel.Joined.Value = false;
}
}