summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJan Dittberner <jan@dittberner.info>2018-03-31 10:50:31 +0200
committerJan Dittberner <jan@dittberner.info>2018-03-31 10:50:31 +0200
commitfd2f3a6e5d81e5b7c49e4817bc86fcf6b9039eea (patch)
tree379ae60211090a92caf835e7e5da4ee98f686a87
parent5977eb5a7a388245b2b956051547516f53bf9222 (diff)
downloadcacert-boardvoting-fd2f3a6e5d81e5b7c49e4817bc86fcf6b9039eea.tar.gz
cacert-boardvoting-fd2f3a6e5d81e5b7c49e4817bc86fcf6b9039eea.tar.xz
cacert-boardvoting-fd2f3a6e5d81e5b7c49e4817bc86fcf6b9039eea.zip
Ignore count of applied migrations from migrate.Exec
-rw-r--r--models.go4
1 files changed, 1 insertions, 3 deletions
diff --git a/models.go b/models.go
index eeb49fc..8c2f968 100644
--- a/models.go
+++ b/models.go
@@ -259,11 +259,9 @@ func NewDB(database *sql.DB) *dbHandler {
log.Panicf("%d statements failed to prepare", len(failedStatements))
}
- version, err := migrate.Exec(database, "sqlite3", dbmig.Migrations(), migrate.Up)
+ _, err := migrate.Exec(database, "sqlite3", dbmig.Migrations(), migrate.Up)
if err != nil {
log.Panicf("running database migration failed: %v", err)
- } else {
- log.Infof("database is now at version %d", version)
}
return handler
}