Skip to content

Commit

Permalink
Update server/backend/migration/20240311000000.go
Browse files Browse the repository at this point in the history
  • Loading branch information
CommanderStorm authored Mar 12, 2024
1 parent cb8cb6a commit 76dad8f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions server/backend/migration/20240311000000.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,10 @@ func migrate20240311000000() *gormigrate.Migration {
return &gormigrate.Migration{
ID: "20240311000000",
Migrate: func(tx *gorm.DB) error {
return tx.Raw("create unique index dish_name_cafeteriaID_uindex on dish (name, cafeteriaID)").Error
return tx.Exec("create unique index dish_name_cafeteriaID_uindex on dish (name, cafeteriaID)").Error
},
Rollback: func(tx *gorm.DB) error {
return tx.Raw("drop index dish_name_cafeteriaID_uindex on dish").Error
return tx.Exec("drop index dish_name_cafeteriaID_uindex on dish").Error
},
}
}

0 comments on commit 76dad8f

Please sign in to comment.