[raffle] Fix index initialization in MySQL v8

which didn't work as `string` is a `LONGTEXT` field which cannot fully
be indexed while MariaDB does not have those issues.

Signed-off-by: Knut Ahlers <knut@ahlers.me>
This commit is contained in:
Knut Ahlers 2023-07-16 00:53:28 +02:00
parent 49b40f5175
commit 6a0c48488b
Signed by: luzifer
GPG key ID: D91C3E91E4CAD6F5

View file

@ -68,7 +68,7 @@ type (
ID uint64 `gorm:"primaryKey" json:"id"`
RaffleID uint64 `gorm:"uniqueIndex:user_per_raffle" json:"-"`
UserID string `gorm:"uniqueIndex:user_per_raffle" json:"userID"`
UserID string `gorm:"size:128;uniqueIndex:user_per_raffle" json:"userID"`
UserLogin string `json:"userLogin"`
UserDisplayName string `json:"userDisplayName"`