We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 9edc82b commit e123c66Copy full SHA for e123c66
2 files changed
common/email.go
@@ -9,6 +9,9 @@ import (
9
)
10
11
func SendEmail(subject string, receiver string, content string) error {
12
+ if SMTPFrom == "" { // for compatibility
13
+ SMTPFrom = SMTPAccount
14
+ }
15
encodedSubject := fmt.Sprintf("=?UTF-8?B?%s?=", base64.StdEncoding.EncodeToString([]byte(subject)))
16
mail := []byte(fmt.Sprintf("To: %s\r\n"+
17
"From: %s<%s>\r\n"+
model/option.go
@@ -60,9 +60,6 @@ func InitOptionMap() {
60
common.SysError("Failed to update option map: " + err.Error())
61
}
62
63
- if common.SMTPFrom == "" { // for compatibility
64
- common.SMTPFrom = common.SMTPAccount
65
- }
66
67
68
func UpdateOption(key string, value string) error {
0 commit comments