diff options
| author | Patrick Barron <barronpm@gmail.com> | 2021-03-17 19:21:03 -0400 |
|---|---|---|
| committer | Patrick Barron <barronpm@gmail.com> | 2021-03-25 19:51:26 -0400 |
| commit | 3ffef5794ea6ddda565d89a58667980f1c3bddc3 (patch) | |
| tree | 4f863280e0e83236fd29cc2fe4e2b0ef74879fa7 | |
| parent | 36669ff45146dd8d4dc063b6a6b1d057f2d33464 (diff) | |
Delete unnecessary indexes
Multicolumn indexes can be queried on the first column without needing a separate index
| -rw-r--r-- | Jellyfin.Server.Implementations/JellyfinDb.cs | 8 |
1 files changed, 0 insertions, 8 deletions
diff --git a/Jellyfin.Server.Implementations/JellyfinDb.cs b/Jellyfin.Server.Implementations/JellyfinDb.cs index 39f842354..eda2fa65c 100644 --- a/Jellyfin.Server.Implementations/JellyfinDb.cs +++ b/Jellyfin.Server.Implementations/JellyfinDb.cs @@ -150,18 +150,10 @@ namespace Jellyfin.Server.Implementations modelBuilder.HasDefaultSchema("jellyfin"); modelBuilder.Entity<DisplayPreferences>() - .HasIndex(entity => entity.UserId) - .IsUnique(false); - - modelBuilder.Entity<DisplayPreferences>() .HasIndex(entity => new { entity.UserId, entity.ItemId, entity.Client }) .IsUnique(); modelBuilder.Entity<CustomItemDisplayPreferences>() - .HasIndex(entity => entity.UserId) - .IsUnique(false); - - modelBuilder.Entity<CustomItemDisplayPreferences>() .HasIndex(entity => new { entity.UserId, entity.ItemId, entity.Client, entity.Key }) .IsUnique(); } |
