Only output "successful" messages when copy actually occurred

This commit is contained in:
Dean Herbert 2022-01-19 10:31:09 +09:00
parent e1a35714be
commit 195534a1d2
1 changed files with 2 additions and 2 deletions

View File

@ -148,10 +148,10 @@ private void migrateBeatmaps(DatabaseWriteUsage ef)
}
transaction.Commit();
Logger.Log($"Successfully migrated {existingBeatmapSets.Count} beatmaps to realm", LoggingTarget.Database);
}
}
Logger.Log($"Successfully migrated {existingBeatmapSets.Count} beatmaps to realm", LoggingTarget.Database);
ef.Context.RemoveRange(existingBeatmapSets);
// Intentionally don't clean up the files, so they don't get purged by EF.
}
@ -257,10 +257,10 @@ private void migrateScores(DatabaseWriteUsage db)
}
transaction.Commit();
Logger.Log($"Successfully migrated {existingScores.Count} scores to realm", LoggingTarget.Database);
}
}
Logger.Log($"Successfully migrated {existingScores.Count} scores to realm", LoggingTarget.Database);
db.Context.RemoveRange(existingScores);
// Intentionally don't clean up the files, so they don't get purged by EF.
}