mirror of
https://github.com/osukey/osukey.git
synced 2025-07-02 00:40:09 +09:00
Optimise file lookups and other database operations
FirstOrDefault when called on a TableQuery with a predicate doesn't use table indices
This commit is contained in:
@ -174,7 +174,7 @@ namespace osu.Game.Beatmaps
|
||||
if (!beatmaps.Delete(beatmapSet)) return;
|
||||
|
||||
if (!beatmapSet.Protected)
|
||||
files.Dereference(beatmapSet.Files.Select(f => f.FileInfo));
|
||||
files.Dereference(beatmapSet.Files.Select(f => f.FileInfo).ToArray());
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
@ -188,7 +188,7 @@ namespace osu.Game.Beatmaps
|
||||
if (!beatmaps.Undelete(beatmapSet)) return;
|
||||
|
||||
if (!beatmapSet.Protected)
|
||||
files.Reference(beatmapSet.Files.Select(f => f.FileInfo));
|
||||
files.Reference(beatmapSet.Files.Select(f => f.FileInfo).ToArray());
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
Reference in New Issue
Block a user