From 365cdfd40ec6710b0d588ccbbcc3004e32f682ca Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bart=C5=82omiej=20Dach?= Date: Thu, 2 Oct 2025 08:52:37 +0200 Subject: [PATCH] Do not overwrite "locally modified" beatmap set status when performing online lookups in song select A relatively recent regression. It's maybe not a huge one, in that it probably doesn't matter all that much, but it is somewhat important to keep the "locally modified" status of the set for as long as possible. One reason for that is that keeping the "locally modified" status will pull up a dialog when the user attempts to update the beatmap, warning them that they will lose their local changes - this dialog will not show if the online lookup flow is allowed to overwrite the map status with something else. --- .../Screens/SelectV2/RealmPopulatingOnlineLookupSource.cs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/osu.Game/Screens/SelectV2/RealmPopulatingOnlineLookupSource.cs b/osu.Game/Screens/SelectV2/RealmPopulatingOnlineLookupSource.cs index 832095058a..16df414037 100644 --- a/osu.Game/Screens/SelectV2/RealmPopulatingOnlineLookupSource.cs +++ b/osu.Game/Screens/SelectV2/RealmPopulatingOnlineLookupSource.cs @@ -82,7 +82,9 @@ namespace osu.Game.Screens.SelectV2 // unfortunately in terms of subscriptions realm treats *every* write to any realm object as a modification, // even if the write was redundant and had no observable effect. - if (dbBeatmapSet.Status != onlineBeatmapSet.Status) + // notably, `LocallyModified` status is preserved on the set until the user performs an explicit action to get rid of it + // (be it updating the set or deciding to discard their changes, removing the set and re-downloading it, etc.) + if (dbBeatmapSet.Status != onlineBeatmapSet.Status && dbBeatmapSet.Status != BeatmapOnlineStatus.LocallyModified) dbBeatmapSet.Status = onlineBeatmapSet.Status; foreach (var dbBeatmap in dbBeatmapSet.Beatmaps)