using DigitalData.MessagingService.Application.Common.Dto; namespace EnvelopeGenerator.Infrastructure.Notification; public static class EnvelopeNotificationExtensions { public static EmailAttachmentDto ToEmailAttachmentDto(this (string FileName, byte[] Content) attachment) => new() { FileName = attachment.FileName, Content = attachment.Content }; public static IEnumerable ToEmailAttachmentDto(this IEnumerable<(string FileName, byte[] Content)> attachments) => attachments.Select(ToEmailAttachmentDto); }