diff --git a/server/AyaNova/Controllers/GlobalOpsNotificationSettingsController.cs b/server/AyaNova/Controllers/GlobalOpsNotificationSettingsController.cs index 84fe71a5..bd057bf2 100644 --- a/server/AyaNova/Controllers/GlobalOpsNotificationSettingsController.cs +++ b/server/AyaNova/Controllers/GlobalOpsNotificationSettingsController.cs @@ -100,6 +100,9 @@ namespace AyaNova.Api.Controllers if (!Authorized.HasModifyRole(HttpContext.Items, AyaType.OpsNotificationSettings))//technically maybe this could be wider open, but for now keeping as locked down return StatusCode(403, new ApiNotAuthorizedResponse()); var res = await CoreJobNotify.TestSMTPDelivery(toAddress); + if(res!="ok"){ + return StatusCode(500, new ApiErrorResponse(ApiErrorCode.API_SERVER_ERROR, null, res)); + } return Ok(ApiOkResponse.Response(res)); }