1
0
mirror of https://github.com/ppy/osu.git synced 2024-11-11 15:47:26 +08:00

Add unique constraint on OnlineBeatmapID

This commit is contained in:
Dean Herbert 2017-11-19 01:42:13 +09:00
parent 7b1083b824
commit 7d2bbc50a3

View File

@ -78,6 +78,7 @@ namespace osu.Game.Database
{
base.OnModelCreating(modelBuilder);
modelBuilder.Entity<BeatmapInfo>().HasIndex(b => b.OnlineBeatmapID).IsUnique();
modelBuilder.Entity<BeatmapInfo>().HasIndex(b => b.MD5Hash).IsUnique();
modelBuilder.Entity<BeatmapInfo>().HasIndex(b => b.Hash).IsUnique();