diff options
author | Unknwon <u@gogs.io> | 2015-09-04 10:59:34 -0400 |
---|---|---|
committer | Unknwon <u@gogs.io> | 2015-09-04 10:59:34 -0400 |
commit | 07fe846c9f64c1b68ed55b42b523c50bf3c23c34 (patch) | |
tree | bbe14389d5dac086c3bda44404f4a79b6881a1b0 /modules/auth | |
parent | d023e81a8f6016db0bdaf8a935f273cc6e0d9a49 (diff) | |
download | gitea-07fe846c9f64c1b68ed55b42b523c50bf3c23c34.tar.gz gitea-07fe846c9f64c1b68ed55b42b523c50bf3c23c34.zip |
#1579 change e-mail max length to 254
Diffstat (limited to 'modules/auth')
-rw-r--r-- | modules/auth/admin.go | 2 | ||||
-rw-r--r-- | modules/auth/user_form.go | 8 |
2 files changed, 5 insertions, 5 deletions
diff --git a/modules/auth/admin.go b/modules/auth/admin.go index a95b83de6a..596e5d642e 100644 --- a/modules/auth/admin.go +++ b/modules/auth/admin.go @@ -12,7 +12,7 @@ import ( type AdminEditUserForm struct { FullName string `form:"fullname" binding:"MaxSize(100)"` - Email string `binding:"Required;Email;MaxSize(50)"` + Email string `binding:"Required;Email;MaxSize(254)"` Password string `binding:"OmitEmpty;MinSize(6);MaxSize(255)"` Website string `binding:"MaxSize(50)"` Location string `binding:"MaxSize(50)"` diff --git a/modules/auth/user_form.go b/modules/auth/user_form.go index e253d60f33..424a410f07 100644 --- a/modules/auth/user_form.go +++ b/modules/auth/user_form.go @@ -59,7 +59,7 @@ func (f *InstallForm) Validate(ctx *macaron.Context, errs binding.Errors) bindin type RegisterForm struct { UserName string `form:"uname" binding:"Required;AlphaDashDot;MaxSize(35)"` - Email string `form:"email" binding:"Required;Email;MaxSize(50)"` + Email string `form:"email" binding:"Required;Email;MaxSize(254)"` Password string `form:"password" binding:"Required;MaxSize(255)"` Retype string `form:"retype"` LoginType string `form:"logintype"` @@ -71,7 +71,7 @@ func (f *RegisterForm) Validate(ctx *macaron.Context, errs binding.Errors) bindi } type SignInForm struct { - UserName string `form:"uname" binding:"Required;MaxSize(35)"` + UserName string `form:"uname" binding:"Required;MaxSize(254)"` Password string `form:"password" binding:"Required;MaxSize(255)"` Remember bool `form:"remember"` } @@ -90,10 +90,10 @@ func (f *SignInForm) Validate(ctx *macaron.Context, errs binding.Errors) binding type UpdateProfileForm struct { UserName string `form:"uname" binding:"Required;MaxSize(35)"` FullName string `form:"fullname" binding:"MaxSize(100)"` - Email string `form:"email" binding:"Required;Email;MaxSize(50)"` + Email string `form:"email" binding:"Required;Email;MaxSize(254)"` Website string `form:"website" binding:"Url;MaxSize(100)"` Location string `form:"location" binding:"MaxSize(50)"` - Avatar string `form:"avatar" binding:"Required;Email;MaxSize(50)"` + Avatar string `form:"avatar" binding:"Required;Email;MaxSize(254)"` } func (f *UpdateProfileForm) Validate(ctx *macaron.Context, errs binding.Errors) binding.Errors { |