From 89b1d8f7dafb684feffa58f003ab6f653b501198 Mon Sep 17 00:00:00 2001 From: Jan Eitzinger Date: Sat, 25 Feb 2023 08:26:56 +0100 Subject: [PATCH] Treat error no change as non fatal --- internal/repository/migration.go | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/internal/repository/migration.go b/internal/repository/migration.go index 258593d..934a002 100644 --- a/internal/repository/migration.go +++ b/internal/repository/migration.go @@ -102,7 +102,11 @@ func MigrateDB(backend string, db string) { } 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()