Skip to content

Commit 10b8da8

Browse files
author
Ludvik Jerabek
committed
Update example and readme
1 parent 0b4e6db commit 10b8da8

2 files changed

Lines changed: 4 additions & 4 deletions

File tree

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ if __name__ == "__main__":
101101
# Add Base64 encoded attachment
102102
message.add_attachment(Attachment("VGhpcyBpcyBhIHRlc3Qh", Disposition.Attachment, "test.txt", "text/plain"))
103103

104-
# Add File attachment from disk, if disposition is not passed, the default is Disposition.ATTACHMENT
104+
# Add File attachment from disk, if disposition is not passed, the default is Disposition.Attachment
105105
message.add_attachment(FileAttachment(r"C:\temp\file.csv", Disposition.Attachment))
106106

107107
# In the following example, we will create a byte stream from a string. This byte array is converted
@@ -111,7 +111,7 @@ if __name__ == "__main__":
111111
# Convert the string into bytes
112112
bytes = text.encode("utf-8")
113113

114-
# Add Byte array as attachment, if disposition is not passed, the default is Disposition.ATTACHMENT
114+
# Add Byte array as attachment, if disposition is not passed, the default is Disposition.Attachment
115115
message.add_attachment(BinaryAttachment(bytes,"bytes.txt", "text/plain", Disposition.Attachment))
116116

117117
result = client.send(message)

example/example.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@
3131
# Add Base64 encoded attachment
3232
message.add_attachment(Attachment("VGhpcyBpcyBhIHRlc3Qh", Disposition.Attachment, "test.txt", "text/plain"))
3333

34-
# Add File attachment from disk, if disposition is not passed, the default is Disposition.ATTACHMENT
34+
# Add File attachment from disk, if disposition is not passed, the default is Disposition.Attachment
3535
message.add_attachment(FileAttachment(r"C:\temp\file.csv", Disposition.Attachment))
3636

3737
# In the following example, we will create a byte stream from a string. This byte array is converted
@@ -41,7 +41,7 @@
4141
# Convert the string into bytes
4242
bytes = text.encode("utf-8")
4343

44-
# Add Byte array as attachment, if disposition is not passed, the default is Disposition.ATTACHMENT
44+
# Add Byte array as attachment, if disposition is not passed, the default is Disposition.Attachment
4545
message.add_attachment(BinaryAttachment(bytes,"bytes.txt", "text/plain", Disposition.Attachment))
4646

4747
result = client.send(message)

0 commit comments

Comments
 (0)