summaryrefslogtreecommitdiffstats
path: root/routers
diff options
context:
space:
mode:
authorUnknwon <u@gogs.io>2015-11-24 18:49:34 -0500
committerUnknwon <u@gogs.io>2015-11-24 18:49:34 -0500
commit7f9598141bd7b0200d9342f01243228eab3061ba (patch)
treec9e5bf147ba72a7f7eb4968f129e32b444b4682b /routers
parent56c66ee486b4b8d544201662de62a23f36e6a069 (diff)
downloadgitea-7f9598141bd7b0200d9342f01243228eab3061ba.tar.gz
gitea-7f9598141bd7b0200d9342f01243228eab3061ba.zip
fix #2020
Diffstat (limited to 'routers')
-rw-r--r--routers/user/auth.go2
-rw-r--r--routers/user/setting.go2
2 files changed, 2 insertions, 2 deletions
diff --git a/routers/user/auth.go b/routers/user/auth.go
index 24ed3673e8..3f37b09059 100644
--- a/routers/user/auth.go
+++ b/routers/user/auth.go
@@ -70,7 +70,7 @@ func SignInPost(ctx *middleware.Context, form auth.SignInForm) {
if form.Remember {
days := 86400 * setting.LogInRememberDays
ctx.SetCookie(setting.CookieUserName, u.Name, days, setting.AppSubUrl)
- ctx.SetSuperSecureCookie(base.EncodeMd5(u.Rands+u.Passwd),
+ ctx.SetSuperSecureCookie(base.EncodeMD5(u.Rands+u.Passwd),
setting.CookieRememberName, u.Name, days, setting.AppSubUrl)
}
diff --git a/routers/user/setting.go b/routers/user/setting.go
index 53b7fdf929..2e825cf56f 100644
--- a/routers/user/setting.go
+++ b/routers/user/setting.go
@@ -79,7 +79,7 @@ func SettingsPost(ctx *middleware.Context, form auth.UpdateProfileForm) {
ctx.User.Email = form.Email
ctx.User.Website = form.Website
ctx.User.Location = form.Location
- ctx.User.Avatar = base.EncodeMd5(form.Gravatar)
+ ctx.User.Avatar = base.EncodeMD5(form.Gravatar)
ctx.User.AvatarEmail = form.Gravatar
if err := models.UpdateUser(ctx.User); err != nil {
ctx.Handle(500, "UpdateUser", err)