Skip to content

Commit a61948c

Browse files
Remove setting senton (#142)
* Always set Representing It seems that it is necessary to set the Representing properties all the time, regardless of whether the message is being sent on behalf of someone else. Outlook seems to be expecting these fields to be present. If they are not, the From field in the folder messages lists will be blank. (Note, if you pop up the message, the from fields will be filled out.) * Fix missing delivery time * Only cast valid email addresses to MailboxAddress Otherwise, the attempted cast with throw an InvalidCastException, in certain situations, which I came across. * Remove Setting SentOn = DateTime.UtcNow It is better to leave this not set rather then setting the time to now, as it is too assuming about the time of the message. I came across this processing emails from 12 years ago and they were showing up as being created today. So, setting the time to now, would be incorrect and just confusing. Better to leave it not set, as it will indicate incomplete information. * Remove Last NewLine To Match Base
1 parent 026b6d4 commit a61948c

File tree

1 file changed

+0
-2
lines changed

1 file changed

+0
-2
lines changed

MsgKit/Email.cs

-2
Original file line numberDiff line numberDiff line change
@@ -478,8 +478,6 @@ internal void WriteToStorage()
478478
if (MessageEditorFormat != MessageEditorFormat.EDITOR_FORMAT_DONTKNOW)
479479
TopLevelProperties.AddProperty(PropertyTags.PR_MSG_EDITOR_FORMAT, MessageEditorFormat);
480480

481-
SentOn ??= DateTime.UtcNow;
482-
483481
if (ReceivedOn.HasValue && ReceivedOn > DateTime.MinValue)
484482
TopLevelProperties.AddProperty(PropertyTags.PR_MESSAGE_DELIVERY_TIME, ReceivedOn.Value.ToUniversalTime());
485483

0 commit comments

Comments
 (0)