From 8eab8c73109dc1b8bd8c7928db4e8f852d2df082 Mon Sep 17 00:00:00 2001 From: life Date: Tue, 27 May 2014 11:21:35 +0800 Subject: [PATCH] fix updateEmail --- app/lea/Email.go | 7 ++++--- app/service/UserService.go | 2 +- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/app/lea/Email.go b/app/lea/Email.go index 8f84c5c..26cf001 100644 --- a/app/lea/Email.go +++ b/app/lea/Email.go @@ -28,8 +28,8 @@ var bodyTpl = `
leanote
-
-   |  $title +
+   |  $title
@@ -50,7 +50,7 @@ var bodyTpl = ` font-size: 12px; } - leanote, your own cloud note + leanote, your own cloud note! @@ -78,6 +78,7 @@ func SendEmail(to, subject, title, body string) bool { err := smtp.SendMail(host+":"+port, auth, username, send_to, msg) if err != nil { + Log(err) return false } return true diff --git a/app/service/UserService.go b/app/service/UserService.go index 9f3e917..19f8073 100644 --- a/app/service/UserService.go +++ b/app/service/UserService.go @@ -208,7 +208,7 @@ func (this *UserService) UpdateEmailSendActiveEmail(userId, email string) (ok bo } // 发送邮件 - url := "http://115.28.133.226/user/updateEmail?token=" + token + url := "http://leanote.com/user/updateEmail?token=" + token body := "邮箱验证后您的登录邮箱为: " + email + "
"; body += fmt.Sprintf("请点击链接验证邮箱: %v. %v小时后过期.", url, url, tokenService.GetOverHours(info.TokenUpdateEmail)); if !SendEmail(email, "leanote-验证邮箱", "验证邮箱", body) {