Fix bindable potentially being set from background thread

This commit is contained in:
smoogipoo 2019-05-09 13:32:18 +09:00
parent 869136b2fb
commit c69d813745

View File

@ -352,10 +352,12 @@ namespace osu.Game.Online.API
public void Logout() public void Logout()
{ {
flushQueue(); flushQueue();
password = null; password = null;
authentication.Clear(); authentication.Clear();
LocalUser.Value = createGuestUser();
State = APIState.Offline; State = APIState.Offline;
Schedule(() => LocalUser.Value = createGuestUser());
} }
private static User createGuestUser() => new GuestUser(); private static User createGuestUser() => new GuestUser();