mirror of
				https://gitee.com/gitea/gitea
				synced 2025-11-04 08:30:25 +08:00 
			
		
		
		
	Fix sender of issue notifications
It is the FROM field in mailer configuration that needs be used, not the USER field, which is for authentication. Closes https://github.com/gogits/gogs/issues/3615
This commit is contained in:
		@@ -160,7 +160,7 @@ func composeIssueMessage(issue *Issue, doer *User, tplName base.TplName, tos []s
 | 
			
		||||
	if err != nil {
 | 
			
		||||
		log.Error(3, "HTMLString (%s): %v", tplName, err)
 | 
			
		||||
	}
 | 
			
		||||
	msg := mailer.NewMessageFrom(tos, fmt.Sprintf(`"%s" <%s>`, doer.DisplayName(), setting.MailService.User), subject, content)
 | 
			
		||||
	msg := mailer.NewMessageFrom(tos, fmt.Sprintf(`"%s" <%s>`, doer.DisplayName(), setting.MailService.FromEmail), subject, content)
 | 
			
		||||
	msg.Info = fmt.Sprintf("Subject: %s, %s", subject, info)
 | 
			
		||||
	return msg
 | 
			
		||||
}
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user