mirror of
https://github.com/woodpecker-ci/woodpecker.git
synced 2025-09-14 13:22:18 +00:00
Fix missing table name (#1817)
Bug from #1806 We don't need the sync because the step_machine is there since the model was added the first time so it mill *always* be in the table
This commit is contained in:
@@ -18,18 +18,9 @@ import (
|
|||||||
"xorm.io/xorm"
|
"xorm.io/xorm"
|
||||||
)
|
)
|
||||||
|
|
||||||
type oldStep017 struct {
|
|
||||||
ID int64 `xorm:"pk autoincr 'step_id'"`
|
|
||||||
Machine string `xorm:"step_machine"`
|
|
||||||
}
|
|
||||||
|
|
||||||
var removeMachineCol = task{
|
var removeMachineCol = task{
|
||||||
name: "remove-machine-col",
|
name: "remove-machine-col",
|
||||||
fn: func(sess *xorm.Session) error {
|
fn: func(sess *xorm.Session) error {
|
||||||
// make sure step_machine column exists
|
|
||||||
if err := sess.Sync(new(oldStep017)); err != nil {
|
|
||||||
return err
|
|
||||||
}
|
|
||||||
return dropTableColumns(sess, "steps", "step_machine")
|
return dropTableColumns(sess, "steps", "step_machine")
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user