summaryrefslogtreecommitdiffstats
path: root/routers/api/v1/org/org.go
diff options
context:
space:
mode:
authorLunny Xiao <xiaolunwen@gmail.com>2017-08-12 22:18:44 +0800
committerGitHub <noreply@github.com>2017-08-12 22:18:44 +0800
commitf960e19c590d27fe62a3a6241f1ea8b7fadde13a (patch)
treecb5045491959550fad930e82434a7f6e27d33cf3 /routers/api/v1/org/org.go
parent921d90fd8b929533e30c896923cb3a6f3d33f45a (diff)
downloadgitea-f960e19c590d27fe62a3a6241f1ea8b7fadde13a.tar.gz
gitea-f960e19c590d27fe62a3a6241f1ea8b7fadde13a.zip
Only update needed columns when update user (#2296)
* only update needed columns when update user * fix missing update_unix column
Diffstat (limited to 'routers/api/v1/org/org.go')
-rw-r--r--routers/api/v1/org/org.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/routers/api/v1/org/org.go b/routers/api/v1/org/org.go
index e4a36b95c0..ec55b9ebe4 100644
--- a/routers/api/v1/org/org.go
+++ b/routers/api/v1/org/org.go
@@ -56,7 +56,7 @@ func Edit(ctx *context.APIContext, form api.EditOrgOption) {
org.Description = form.Description
org.Website = form.Website
org.Location = form.Location
- if err := models.UpdateUser(org); err != nil {
+ if err := models.UpdateUserCols(org, "full_name", "description", "website", "location"); err != nil {
ctx.Error(500, "UpdateUser", err)
return
}