diff options
author | Alex Gleason <alex@alexgleason.me> | 2020-09-21 13:28:02 -0500 |
---|---|---|
committer | Alex Gleason <alex@alexgleason.me> | 2020-09-21 13:28:02 -0500 |
commit | 8b6ac45f3cb5a3c1ac16e766a6f503ee491bc310 (patch) | |
tree | cf6f31ee713f9d8cb3435ed35c4851b12e1b31c7 | |
parent | a0f5e8b27edbe2224d9c2c3997ad5b8ea484244b (diff) | |
download | pleroma-8b6ac45f3cb5a3c1ac16e766a6f503ee491bc310.tar.gz |
Allow emails to be sent again, #2101 #2172
https://github.com/swoosh/swoosh/issues/478#issuecomment-642393707
-rw-r--r-- | lib/pleroma/emails/mailer.ex | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/pleroma/emails/mailer.ex b/lib/pleroma/emails/mailer.ex index 8b1bdef75..5108c71c8 100644 --- a/lib/pleroma/emails/mailer.ex +++ b/lib/pleroma/emails/mailer.ex @@ -35,6 +35,11 @@ defmodule Pleroma.Emails.Mailer do def deliver(email, config \\ []) def deliver(email, config) do + # temporary hackney fix until hackney max_connections bug is fixed + # https://git.pleroma.social/pleroma/pleroma/-/issues/2101 + email = + Swoosh.Email.put_private(email, :hackney_options, ssl_options: [versions: [:"tlsv1.2"]]) + case enabled?() do true -> Swoosh.Mailer.deliver(email, parse_config(config)) false -> {:error, :deliveries_disabled} |