mirror of
https://github.com/osukey/osukey.git
synced 2025-07-03 01:09:57 +09:00
Replace usage of .Result
with .WaitSafelyForResult
This commit is contained in:
@ -7,6 +7,7 @@ using System.Linq;
|
||||
using JetBrains.Annotations;
|
||||
using osu.Framework.Allocation;
|
||||
using osu.Framework.Bindables;
|
||||
using osu.Framework.Extensions;
|
||||
using osu.Framework.Extensions.ObjectExtensions;
|
||||
using osu.Game.Beatmaps;
|
||||
using osu.Game.Database;
|
||||
@ -57,9 +58,11 @@ namespace osu.Game.Screens.Spectate
|
||||
{
|
||||
base.LoadComplete();
|
||||
|
||||
userLookupCache.GetUsersAsync(users.ToArray()).ContinueWith(users => Schedule(() =>
|
||||
userLookupCache.GetUsersAsync(users.ToArray()).ContinueWith(task => Schedule(() =>
|
||||
{
|
||||
foreach (var u in users.Result)
|
||||
var foundUsers = task.WaitSafelyForResult();
|
||||
|
||||
foreach (var u in foundUsers)
|
||||
{
|
||||
if (u == null)
|
||||
continue;
|
||||
|
Reference in New Issue
Block a user