mirror of
https://github.com/ClusterCockpit/cc-backend
synced 2024-12-26 05:19:05 +01:00
Allow up and down migration of database
This commit is contained in:
parent
105b7eabf0
commit
2c2c1accb5
@ -114,7 +114,7 @@ func MigrateDB(backend string, db string) error {
|
||||
return err
|
||||
}
|
||||
|
||||
if err := m.Up(); err != nil {
|
||||
if err := m.Migrate(Version); err != nil {
|
||||
if err == migrate.ErrNoChange {
|
||||
log.Info("DB already up to date!")
|
||||
} else {
|
||||
|
Loading…
Reference in New Issue
Block a user