Skip to content

Commit e64c0d1

Browse files
committed
Update README to show addAttachment argument order
1 parent 151a956 commit e64c0d1

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -131,11 +131,11 @@ email.setHtml("<h1>My first email through SendGrid");
131131
### Attachments
132132
133133
```java
134-
email.addAttachment("contents", "text.txt");
134+
email.addAttachment("text.txt", "contents");
135135
// or
136-
email.addAttachment(new File("./file.txt"), "text.txt");
136+
email.addAttachment("image.png", new File("./image.png"));
137137
// or
138-
email.addAttachment(new InputStream(new File("./file.txt")), "text.txt");
138+
email.addAttachment("text.txt", new InputStream(new File("./file.txt")));
139139
```
140140
141141
## [X-SMTPAPI](http://sendgrid.com/docs/API_Reference/SMTP_API/index.html)

0 commit comments

Comments
 (0)