Fixed goose API break.

This commit is contained in:
Patrick Fairbank
2014-09-06 19:19:37 -07:00
parent 370e697b99
commit e35f4157ab

View File

@@ -38,7 +38,7 @@ type Database struct {
func OpenDatabase(path string) (*Database, error) {
// Find and run the migrations using goose. This also auto-creates the DB.
dbDriver := goose.DBDriver{"sqlite3", path, "github.com/mattn/go-sqlite3", &goose.Sqlite3Dialect{}}
dbConf := goose.DBConf{migrationsDir, "prod", dbDriver}
dbConf := goose.DBConf{MigrationsDir: migrationsDir, Env: "prod", Driver: dbDriver}
target, err := goose.GetMostRecentDBVersion(migrationsDir)
if err != nil {
return nil, err