mirror of
https://github.com/woodpecker-ci/woodpecker.git
synced 2024-11-22 01:41:02 +00:00
Fix cron migration (#4020)
This commit is contained in:
parent
eeec084293
commit
67a9c7991c
1 changed files with 3 additions and 2 deletions
|
@ -42,8 +42,9 @@ var cronWithoutSec = xormigrate.Migration{
|
|||
continue
|
||||
}
|
||||
|
||||
c.Schedule = strings.SplitN(strings.TrimSpace(c.Schedule), " ", 2)[1]
|
||||
if _, err := sess.Update(c); err != nil {
|
||||
if _, err := sess.Update(&model.Cron{
|
||||
Schedule: strings.SplitN(strings.TrimSpace(c.Schedule), " ", 2)[1],
|
||||
}, c); err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue