Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MailKitSender - make it possible to preprocess MimeMessage instances after creation before sending #388

Open
emayevski opened this issue Aug 29, 2024 · 0 comments

Comments

@emayevski
Copy link

emayevski commented Aug 29, 2024

Current implementation of Send and SendAsync calls CreateMailMessage() to create an instance of MimeMessage. After that, the message can be DKIM-signed. The problem is that CreateMailMessage() is a private method, and there's no other place to hook into the process. My suggestion/request is that either CreateMailMessage is made virtual protected, or there's another virtual protected method introduced, which would be called after CreateMailMessage completes. The first option is of course simpler and require changing one word (private) to two. Then, one would be able to subclass the MailKitSender class and override the method, adding the necessary functionality.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant