diff --git a/MailComponent/Mail/InternetMailAttachment.cs b/MailComponent/Mail/InternetMailAttachment.cs index c6e4a64..ec95d45 100644 --- a/MailComponent/Mail/InternetMailAttachment.cs +++ b/MailComponent/Mail/InternetMailAttachment.cs @@ -17,10 +17,10 @@ namespace OneScript.InternetMail [ContextClass("ИнтернетПочтовоеВложение", "InternetMailAttachment")] public class InternetMailAttachment : AutoContext { - /// - /// Пустое почтовое вложение - /// - public InternetMailAttachment() + /// + /// Пустое почтовое вложение + /// + public InternetMailAttachment() { EncodingMode = InternetMailAttachmentEncodingMode.Mime; Data = ValueFactory.Create(); diff --git a/MailComponent/Mail/InternetMailAttachments.cs b/MailComponent/Mail/InternetMailAttachments.cs index ac8552c..c51473c 100644 --- a/MailComponent/Mail/InternetMailAttachments.cs +++ b/MailComponent/Mail/InternetMailAttachments.cs @@ -62,7 +62,7 @@ public InternetMailAttachment Add(BinaryDataContext data, string attachmentName { var attachment = new InternetMailAttachment(data, attachmentName); attachment.Name = attachmentName; - _data.Add(attachment); + _data.Add(attachment); return attachment; } diff --git a/MailComponent/Mail/InternetMailMessage.cs b/MailComponent/Mail/InternetMailMessage.cs index eaf937b..502cfde 100644 --- a/MailComponent/Mail/InternetMailMessage.cs +++ b/MailComponent/Mail/InternetMailMessage.cs @@ -94,7 +94,7 @@ public InternetMailMessage(MailKit.IMessageSummary headers) : this(GenerateHeade public InternetMailMessage(MimeMessage nativeMessage, string identifier) : this(nativeMessage.Headers) { - + Uid.Add(ValueFactory.Create(identifier)); if (nativeMessage.Body is TextPart) { @@ -102,7 +102,7 @@ public InternetMailMessage(MimeMessage nativeMessage, string identifier) : this( } else if (nativeMessage.Body is Multipart) { - + var body = nativeMessage.Body as Multipart; foreach (var part in body) { @@ -133,7 +133,7 @@ public InternetMailMessage(MimeMessage nativeMessage, string identifier) : this( var part = (MimePart)attachment; var fileName = part.FileName; var stream = new MemoryStream(); - + part.ContentObject.DecodeTo(stream); BinaryDataContext bin = new BinaryDataContext(stream.ToArray()); Attachments.Add(bin, fileName); diff --git a/MailComponent/Mail/InternetMailMessageImportance.cs b/MailComponent/Mail/InternetMailMessageImportance.cs index fac6457..3f7d1fc 100644 --- a/MailComponent/Mail/InternetMailMessageImportance.cs +++ b/MailComponent/Mail/InternetMailMessageImportance.cs @@ -5,7 +5,6 @@ This Source Code Form is subject to the terms of the at http://mozilla.org/MPL/2.0/. ----------------------------------------------------------*/ using System; -using ScriptEngine.Machine.Contexts; using ScriptEngine; namespace OneScript.InternetMail diff --git a/TestApp/Program.cs b/TestApp/Program.cs index d7fc1fb..46672c0 100755 --- a/TestApp/Program.cs +++ b/TestApp/Program.cs @@ -1,4 +1,10 @@ -using System; +/*---------------------------------------------------------- +This Source Code Form is subject to the terms of the +Mozilla Public License, v.2.0. If a copy of the MPL +was not distributed with this file, You can obtain one +at http://mozilla.org/MPL/2.0/. +----------------------------------------------------------*/ +using System; using System.IO; using ScriptEngine.Machine; using ScriptEngine.HostedScript;