summaryrefslogtreecommitdiffstats
path: root/models
diff options
context:
space:
mode:
authorUnknwon <joe2010xtmf@163.com>2015-02-04 20:04:01 -0500
committerUnknwon <joe2010xtmf@163.com>2015-02-04 20:04:01 -0500
commitf706102890af33c14aa9afc7e62a4c2dd52bd2a4 (patch)
treedf207665e2a986afc64abb46e3a629113f8c83d8 /models
parent7140f50637219cbaffcf21d5082cf6b5c9f1994c (diff)
downloadgitea-f706102890af33c14aa9afc7e62a4c2dd52bd2a4.tar.gz
gitea-f706102890af33c14aa9afc7e62a4c2dd52bd2a4.zip
models: sanitize user full name when update settings
Diffstat (limited to 'models')
-rw-r--r--models/user.go1
1 files changed, 1 insertions, 0 deletions
diff --git a/models/user.go b/models/user.go
index f16fbca344..2da0881c81 100644
--- a/models/user.go
+++ b/models/user.go
@@ -477,6 +477,7 @@ func UpdateUser(u *User) error {
}
u.Avatar = avatar.HashEmail(u.AvatarEmail)
+ u.FullName = base.Sanitizer.Sanitize(u.FullName)
_, err = x.Id(u.Id).AllCols().Update(u)
return err
}