From e12025dd48018cbdf4feb298026539b4878f2591 Mon Sep 17 00:00:00 2001 From: Dean Herbert Date: Wed, 12 Jan 2022 16:17:11 +0900 Subject: [PATCH] Cascade delete metadata when beatmaps are deleted --- osu.Game/Database/RealmContextFactory.cs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/osu.Game/Database/RealmContextFactory.cs b/osu.Game/Database/RealmContextFactory.cs index 1aa6b2043c..0802641b06 100644 --- a/osu.Game/Database/RealmContextFactory.cs +++ b/osu.Game/Database/RealmContextFactory.cs @@ -121,6 +121,8 @@ private void cleanupPendingDeletions() foreach (var score in beatmap.Scores) realm.Remove(score); + realm.Remove(beatmap.Metadata); + realm.Remove(beatmap); }