mirror of
https://github.com/mattermost/mattermost.git
synced 2025-02-25 18:55:24 -06:00
Only include the avatar attachment if is going to show a message in the invitation (#12747)
This commit is contained in:
@@ -445,9 +445,11 @@ func (a *App) SendGuestInviteEmails(team *model.Team, channels []*model.Channel,
|
||||
}
|
||||
|
||||
embeddedFiles := make(map[string]io.Reader)
|
||||
if senderProfileImage != nil {
|
||||
embeddedFiles = map[string]io.Reader{
|
||||
"user-avatar.png": bytes.NewReader(senderProfileImage),
|
||||
if message != "" {
|
||||
if senderProfileImage != nil {
|
||||
embeddedFiles = map[string]io.Reader{
|
||||
"user-avatar.png": bytes.NewReader(senderProfileImage),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user