fix anwser token and database issus
This commit is contained in:
@@ -54,10 +54,11 @@ func SendPasswordRecoveryMail(email, code string) error {
|
||||
}
|
||||
|
||||
// SendNewFollowUpMail 通知提问箱主人:有人对某条已回答的提问进行了追问。
|
||||
// 链接无需 token,主人登录后即可查看。
|
||||
func SendNewFollowUpMail(email, domain string, questionID uint, questionContent string, followUpContent string) error {
|
||||
// 链接带 token,与 SendNewQuestionMail 对齐——主人于未登录设备(手机邮件客户端)点开私密提问时
|
||||
// 也能凭 token 查看,否则会被 Questioner 中间件重定向到首页。
|
||||
func SendNewFollowUpMail(email, domain string, questionID uint, questionContent string, followUpContent string, token string) error {
|
||||
params := map[string]string{
|
||||
"link": fmt.Sprintf("%s/_/%s/%d", conf.App.ExternalURL, domain, questionID),
|
||||
"link": fmt.Sprintf("%s/_/%s/%d?t=%s", conf.App.ExternalURL, domain, questionID, token),
|
||||
"question": questionContent,
|
||||
"followup": followUpContent,
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user