Fix where syntax (#2676)

This commit is contained in:
qwerty287 2023-10-31 12:43:06 +01:00 committed by GitHub
parent 8a21a4c08e
commit 9c07b15c99
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -43,10 +43,7 @@ func (s storage) ServerConfigSet(key, value string) error {
return err return err
} }
// TODO change to Where() when https://gitea.com/xorm/xorm/issues/2358 is solved _, err = s.engine.Where("`key` = ?", config.Key).Cols("value").Update(config)
_, err = s.engine.Cols("value").Update(config, &model.ServerConfig{
Key: key,
})
return err return err
} }