Return transaction Begin error in v9 migration

pull/295/head
Matt Baer 5 years ago
parent a0e517c224
commit b9c467558c
  1. 4
      migrations/v9.go

@ -12,6 +12,10 @@ package migrations
func optimizeDrafts(db *datastore) error {
t, err := db.Begin()
if err != nil {
t.Rollback()
return err
}
_, err = t.Exec(`ALTER TABLE posts ADD INDEX(owner_id, id)`)
if err != nil {

Loading…
Cancel
Save