mirror of
https://github.com/ppy/osu.git
synced 2025-01-12 19:42:55 +08:00
Add assertion on realm re-fetch being not-null
This commit is contained in:
parent
2b278ed324
commit
01487a1185
@ -3,6 +3,7 @@
|
||||
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Diagnostics;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using osu.Framework.Platform;
|
||||
@ -46,6 +47,7 @@ namespace osu.Game.Database
|
||||
Realm.Realm.Write(realm =>
|
||||
{
|
||||
var managed = realm.Find<TModel>(item.ID);
|
||||
Debug.Assert(managed != null);
|
||||
operation(managed);
|
||||
|
||||
item.Files.Clear();
|
||||
|
Loading…
Reference in New Issue
Block a user