fix: fuck

This commit is contained in:
orion 2023-12-12 19:24:43 -06:00
parent ef0191e573
commit 6c83726c53
Signed by: orion
GPG Key ID: 6D4165AE4C928719

View File

@ -84,12 +84,12 @@ deliverableOnce :: Email -> ExceptT EmailError Aff Email
deliverableOnce email' = do
let email = Email.toString email'
{ reachable, syntax, mx, smtp } <- lift $ Promise.toAffE $ checkEmailImpl email
when (not reachable) $ throwError $ EmailUnreachable email'
when (not syntax.valid) $ throwError $ EmailSyntaxInvalid email'
when (not mx.valid) $ throwError $ EmailMXInvalid email'
when (not smtp.valid) $ throwError $ EmailSMTPInvalid email'
when (maybe true Array.null $ Nullable.toMaybe $ mx.mxRecords) $ throwError $ EmailMXNoRecords email'
for_ (Nullable.toMaybe $ smtp.error) $ throwError <<< EmailSMTPError email'
when (not reachable) $ throwError $ EmailUnreachable email'
pure email'
deliverable :: Email -> ExceptT EmailError Aff Email