Skip to content

Commit

Permalink
fit: gmail (cloudreve#1949)
Browse files Browse the repository at this point in the history
  • Loading branch information
liaosunny123 authored Feb 24, 2024
1 parent 88409cc commit 3edb00a
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions pkg/email/smtp.go
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
package email

import (
"fmt"
"github.com/google/uuid"
"time"

"github.com/cloudreve/Cloudreve/v3/pkg/util"
Expand Down Expand Up @@ -50,6 +52,7 @@ func (client *SMTP) Send(to, title, body string) error {
m.SetAddressHeader("Reply-To", client.Config.ReplyTo, client.Config.Name)
m.SetHeader("To", to)
m.SetHeader("Subject", title)
m.SetHeader("Message-ID", fmt.Sprintf("<%s@%s>", uuid.NewString(), "cloudreve"))
m.SetBody("text/html", body)
client.ch <- m
return nil
Expand Down

0 comments on commit 3edb00a

Please # to comment.