Skip to content

Commit

Permalink
Fixed ordering on lines of code for setting dummy draft when submitti…
Browse files Browse the repository at this point in the history
…ng file attachments. This fixed problem that no message was sent when sending attachments. (#232)
  • Loading branch information
durnin authored Jul 8, 2024
1 parent 6d090a1 commit f57e996
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/ews/message_accessors.rb
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,8 @@ def send_message(opts = {}, &block)
yield msg if block_given?
if msg.has_attachments?
draft = msg.draft
msg.draft = true
resp = parse_create_item(ews.create_item(msg.to_ews))
msg.draft = true
msg.file_attachments.each do |f|
next unless f.kind_of?(File) or f.kind_of?(Tempfile)
resp.add_file_attachment(f)
Expand Down

0 comments on commit f57e996

Please sign in to comment.