Skip to content

Commit

Permalink
fix nil pointer dereference
Browse files Browse the repository at this point in the history
  • Loading branch information
vtopc committed Sep 15, 2024
1 parent 2ef9285 commit c09c4e5
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions messages.go
Original file line number Diff line number Diff line change
Expand Up @@ -914,6 +914,9 @@ func (mg *MailgunImpl) GetStoredAttachment(ctx context.Context, url string) ([]b
r.addHeader("Accept", "message/rfc2822")

response, err := makeGetRequest(ctx, r)
if err != nil {
return nil, err
}

return response.Data, err
}

0 comments on commit c09c4e5

Please sign in to comment.