mirror of https://gitee.com/answerdev/answer.git
fix(plugin): fix update plugin status to default
This commit is contained in:
parent
496df590e8
commit
df9b08abcf
|
@ -18,10 +18,6 @@ func addPlugin(x *xorm.Engine) error {
|
|||
return fmt.Errorf("get config failed: %w", err)
|
||||
}
|
||||
if exist {
|
||||
if _, err = x.Update(c, &entity.Config{ID: c.ID, Key: c.Key}); err != nil {
|
||||
log.Errorf("update %+v config failed: %s", c, err)
|
||||
return fmt.Errorf("update config failed: %w", err)
|
||||
}
|
||||
continue
|
||||
}
|
||||
if _, err = x.Insert(&entity.Config{ID: c.ID, Key: c.Key, Value: c.Value}); err != nil {
|
||||
|
|
Loading…
Reference in New Issue