add mail address change warning for invited accounts (#6377)

add a new mail template to differentiate between existing accounts and
only invited accounts, so that they can easier delete the
existing placeholder account
This commit is contained in:
Stefan Melmuk
2025-10-21 19:21:47 +02:00
committed by GitHub
parent 8043f7eca7
commit d43edb8f17
5 changed files with 69 additions and 3 deletions

View File

@@ -588,6 +588,20 @@ pub async fn send_change_email_existing(address: &str, acting_address: &str) ->
send_email(address, &subject, body_html, body_text).await
}
pub async fn send_change_email_invited(address: &str, acting_address: &str) -> EmptyResult {
let (subject, body_html, body_text) = get_text(
"email/change_email_invited",
json!({
"url": CONFIG.domain(),
"img_src": CONFIG._smtp_img_src(),
"existing_address": address,
"acting_address": acting_address,
}),
)?;
send_email(address, &subject, body_html, body_text).await
}
pub async fn send_sso_change_email(address: &str) -> EmptyResult {
let (subject, body_html, body_text) = get_text(
"email/sso_change_email",