refactor: remove pre_encrypt_mime_hook

It is only used in a single test
and the test is more reliable by having a blob .eml
that will not be accidentally modified
by mimefactory changes.
This commit is contained in:
link2xt
2026-05-24 01:27:54 +02:00
committed by l
parent 627f98915d
commit 480248a168
5 changed files with 78 additions and 46 deletions

View File

@@ -1168,12 +1168,6 @@ impl MimeFactory {
_ => None,
};
if context.get_config_bool(Config::TestHooks).await?
&& let Some(hook) = &*context.pre_encrypt_mime_hook.lock()
{
message = hook(context, message);
}
let encrypted = if let Some(shared_secret) = shared_secret {
let sign = true;
encrypt_helper