mirror of
https://github.com/osukey/osukey.git
synced 2025-08-02 22:26:41 +09:00
Schedule API callback to own scheduler
Fixes race condition when API returns a failure after exiting song select. Note that the API does also schedule to the correct thread, but this schedule ensures the callback is never run, which is what we want in this case.
This commit is contained in:
@ -86,7 +86,7 @@ namespace osu.Game.Screens.Select
|
||||
requestedBeatmap.Metrics = res;
|
||||
Schedule(() => updateMetrics(res));
|
||||
};
|
||||
lookup.Failure += e => updateMetrics(null);
|
||||
lookup.Failure += e => Schedule(() => updateMetrics(null));
|
||||
|
||||
api.Queue(lookup);
|
||||
loading.Show();
|
||||
|
Reference in New Issue
Block a user