From 680b577f1bc90ae19e7c3388bbe9216c39ab93eb Mon Sep 17 00:00:00 2001 From: Thomas Citharel Date: Mon, 5 Oct 2020 14:45:58 +0200 Subject: [PATCH 1/2] Fix typo in atom name Signed-off-by: Thomas Citharel --- lib/service/auth/ldap_authenticator.ex | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/service/auth/ldap_authenticator.ex b/lib/service/auth/ldap_authenticator.ex index a05fc946d..e42be59d9 100644 --- a/lib/service/auth/ldap_authenticator.ex +++ b/lib/service/auth/ldap_authenticator.ex @@ -78,7 +78,7 @@ defmodule Mobilizon.Service.Auth.LDAPAuthenticator do end else {:error, err} - when err in [:ldap_search_email_not_found, :ldap_search_email_not_found] -> + when err in [:ldap_search_email_not_found, :ldap_search_missing_attributes] -> {:ldap, err} {:error, error} -> @@ -146,7 +146,7 @@ defmodule Mobilizon.Service.Auth.LDAPAuthenticator do {:cn, err} -> Logger.error("Could not find LDAP attribute CN: #{inspect(err)}") - {:error, :ldap_searcy_missing_attributes} + {:error, :ldap_search_missing_attributes} error -> error From 0b3d1584703d9bd052c42a62113fae7b592e49f1 Mon Sep 17 00:00:00 2001 From: Thomas Citharel Date: Mon, 5 Oct 2020 14:46:08 +0200 Subject: [PATCH 2/2] Fix issues in email change emails Signed-off-by: Thomas Citharel --- lib/web/templates/email/email_changed_new.html.eex | 2 +- lib/web/templates/email/email_changed_old.html.eex | 7 +++++++ 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/lib/web/templates/email/email_changed_new.html.eex b/lib/web/templates/email/email_changed_new.html.eex index 374d25f14..f3eb0267b 100644 --- a/lib/web/templates/email/email_changed_new.html.eex +++ b/lib/web/templates/email/email_changed_new.html.eex @@ -35,7 +35,7 @@

- <%= gettext "Hi there! It seems like you wanted to change the email address linked to your account on %{instance}. If you still wish to do so, please click the button below to confirm the change. You will then be able to log in to %{instance} with this new email address.", %{instance: @instance_name} %> + <%= gettext("Hi there! It seems like you wanted to change the email address linked to your account on %{instance}. If you still wish to do so, please click the button below to confirm the change. You will then be able to log in to %{instance} with this new email address.", %{instance: @instance_name}) |> raw %>

diff --git a/lib/web/templates/email/email_changed_old.html.eex b/lib/web/templates/email/email_changed_old.html.eex index 0d45d28eb..a4c2acd0c 100644 --- a/lib/web/templates/email/email_changed_old.html.eex +++ b/lib/web/templates/email/email_changed_old.html.eex @@ -59,6 +59,13 @@ + + +

+ <%= gettext("If you did not trigger this change yourself, it is likely that someone has gained access to your %{host} account. Please log in and change your password immediately. If you cannot login, contact the admin on %{host}.", host: @instance[:name]) %> +

+ +