feat(database): add repairSmokeAIAdviceIndexes function and corresponding tests
- Implemented repairSmokeAIAdviceIndexes to manage the unique index for fa_smoke_ai_advice. - Added unit tests for the new function to ensure correct index recreation and validation. - Updated AutoMigrate to include the new index repair function.
This commit is contained in:
@@ -102,6 +102,9 @@ func AutoMigrate(models ...interface{}) error {
|
||||
if err := repairSmokeAINextSmokeIndexes(DB); err != nil {
|
||||
return err
|
||||
}
|
||||
if err := repairSmokeAIAdviceIndexes(DB); err != nil {
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user