Persist `DateAdded` over beatmap updates

This commit is contained in:
Dean Herbert 2022-07-25 18:55:08 +09:00
parent e5ad07454c
commit 2363a3fb7b
1 changed files with 3 additions and 0 deletions

View File

@ -38,6 +38,9 @@ void onSuccess(Live<BeatmapSetInfo> imported)
// but that isn't a guarantee (ie. if the .osu file doesn't have OnlineIDs populated).
original.DeletePending = true;
// Transfer local values which should be persisted across a beatmap update.
updated.DateAdded = original.DateAdded;
foreach (var beatmap in original.Beatmaps.ToArray())
{
var updatedBeatmap = updated.Beatmaps.FirstOrDefault(b => b.Hash == beatmap.Hash);