summaryrefslogtreecommitdiffstats
path: root/modules
diff options
context:
space:
mode:
authorUnknown <joe2010xtmf@163.com>2014-04-03 16:33:27 -0400
committerUnknown <joe2010xtmf@163.com>2014-04-03 16:33:27 -0400
commite9c4156c874ceeecc81fdf7fe00ff2f582110ecd (patch)
tree091d17fbfa89444ab16c97d4c4b8da361a1c6ad8 /modules
parent79a610592ea7c2e93ab2f91190af1782c4aa8f8d (diff)
downloadgitea-e9c4156c874ceeecc81fdf7fe00ff2f582110ecd.tar.gz
gitea-e9c4156c874ceeecc81fdf7fe00ff2f582110ecd.zip
Add: rename user
Diffstat (limited to 'modules')
-rw-r--r--modules/auth/user.go2
1 files changed, 2 insertions, 0 deletions
diff --git a/modules/auth/user.go b/modules/auth/user.go
index 2d3c29fde1..015059f7dc 100644
--- a/modules/auth/user.go
+++ b/modules/auth/user.go
@@ -75,6 +75,7 @@ type FeedsForm struct {
}
type UpdateProfileForm struct {
+ UserName string `form:"username" binding:"Required;AlphaDash;MaxSize(30)"`
Email string `form:"email" binding:"Required;Email;MaxSize(50)"`
Website string `form:"website" binding:"MaxSize(50)"`
Location string `form:"location" binding:"MaxSize(50)"`
@@ -83,6 +84,7 @@ type UpdateProfileForm struct {
func (f *UpdateProfileForm) Name(field string) string {
names := map[string]string{
+ "UserName": "Username",
"Email": "E-mail address",
"Website": "Website",
"Location": "Location",