Describe the bug
When call Mime.Message.Load using filestream data for an email file containing an attachment with ".HTM" extension is not working as expected. Message.Attachment count is read as 0. For some reason, the attachment is being considered as body of email. We can see in MessagePart, that the attachment flag is set to true. This was working fine with version 5.5.1.
To Reproduce
Steps to reproduce the behavior:
Read email file with no body and a single attachment with .HTM extension as file stream and then call Message.Load on the filestream. Inspect the attachment property of Message object.
Our code snippet:
using MsgReader.Mime;
Message poMailMessage = null;
string faxContentString = "email notice string";
Stream file = StreamContentHelper.GenerateStreamFromString(faxContentString);
try
{
poMailMessage = Message.Load(file);
}
Expected behavior
We expect that when we load the message using Message.Load, the attachment is identified properly.
Screenshots
If applicable, add screenshots to help explain your problem.
MsgReader 5.5.9
MsgReader 5.5.1 did not have the issue
Additional context
Some more information:
Net8 framework
I have also attached a sample eml file. I had to zip it since github does not allow to attach .eml file directly. The eml file works fine with MsgReader 5.5.1 and does not work with 5.5.7 upwards
Describe the bug When call Mime.Message.Load using filestream data for an email file containing an attachment with ".HTM" extension is not working as expected. Message.Attachment count is read as 0. For some reason, the attachment is being considered as body of email. We can see in MessagePart, that the attachment flag is set to true. This was working fine with version 5.5.1.
To Reproduce Steps to reproduce the behavior: Read email file with no body and a single attachment with .HTM extension as file stream and then call Message.Load on the filestream. Inspect the attachment property of Message object. Our code snippet: using MsgReader.Mime; Message poMailMessage = null; string faxContentString = "email notice string"; Stream file = StreamContentHelper.GenerateStreamFromString(faxContentString); try { poMailMessage = Message.Load(file); }
Expected behavior We expect that when we load the message using Message.Load, the attachment is identified properly.
Screenshots If applicable, add screenshots to help explain your problem. MsgReader 5.5.9
MsgReader 5.5.1 did not have the issue
Additional context Some more information:
Net8 framework I have also attached a sample eml file. I had to zip it since github does not allow to attach .eml file directly. The eml file works fine with MsgReader 5.5.1 and does not work with 5.5.7 upwards
t7s071a3p500e50crnq71rqrmd9e385fuuhj03g1DevTestSan.zip