Update all usages of CreateContext to use either Run or Write

This commit is contained in:
Dean Herbert
2022-01-21 17:08:20 +09:00
parent da0a803e6c
commit 114c9e8c1f
22 changed files with 230 additions and 250 deletions

View File

@ -147,7 +147,7 @@ namespace osu.Game.Screens.Select.Leaderboards
if (Scope == BeatmapLeaderboardScope.Local)
{
using (var realm = realmFactory.CreateContext())
realmFactory.Run(realm =>
{
var scores = realm.All<ScoreInfo>()
.AsEnumerable()
@ -171,9 +171,9 @@ namespace osu.Game.Screens.Select.Leaderboards
scoreManager.OrderByTotalScoreAsync(scores.ToArray(), cancellationToken)
.ContinueWith(ordered => scoresCallback?.Invoke(ordered.GetResultSafely()), TaskContinuationOptions.OnlyOnRanToCompletion);
});
return null;
}
return null;
}
if (api?.IsLoggedIn != true)