From 0234ba7e48d6dd87c1cdbd546aef185a66d064ae Mon Sep 17 00:00:00 2001 From: Valentin Tolmer <valentin@tolmer.fr> Date: Fri, 15 Apr 2022 19:52:14 +0200 Subject: [PATCH] server: Report errors sending email --- server/src/infra/auth_service.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/server/src/infra/auth_service.rs b/server/src/infra/auth_service.rs index a1d3fca..67def73 100644 --- a/server/src/infra/auth_service.rs +++ b/server/src/infra/auth_service.rs @@ -156,6 +156,7 @@ where &data.mail_options, ) { warn!("Error sending email: {:#?}", e); + return HttpResponse::InternalServerError().body(format!("Could not send email: {}", e)); } HttpResponse::Ok().finish() }