mirror of
https://github.com/ClusterCockpit/cc-backend
synced 2024-11-10 08:57:25 +01:00
Treat error no change as non fatal
This commit is contained in:
parent
252ec3909a
commit
89b1d8f7da
@ -102,8 +102,12 @@ func MigrateDB(backend string, db string) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if err := m.Up(); err != nil {
|
if err := m.Up(); err != nil {
|
||||||
|
if err == migrate.ErrNoChange {
|
||||||
|
log.Info("DB already up to date!")
|
||||||
|
} else {
|
||||||
log.Fatal(err)
|
log.Fatal(err)
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
m.Close()
|
m.Close()
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user