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