mirror of
https://github.com/floci-io/floci.git
synced 2026-11-24 14:30:28 -05:00
fix(ses): omit MailFromAttributes if MAIL FROM domain is not configured (#1273)
This commit is contained in:
1 parent
ee341003bf
commit
f8cf476848
3 files changed
+18
-11
No files matched your search
@@ -1080,13 +1080,13 @@ public class SesController {
|
||||
|
||||
result.set("DkimAttributes", buildDkimAttributes(identity));
|
||||
|
||||
ObjectNode mailFromAttributes = result.putObject("MailFromAttributes");
|
||||
String mailFromDomain = identity.getMailFromDomain();
|
||||
mailFromAttributes.put("MailFromDomain", mailFromDomain == null ? "" : mailFromDomain);
|
||||
mailFromAttributes.put("MailFromDomainStatus",
|
||||
mailFromDomain == null ? "NOT_STARTED" : toV2Status(identity.getMailFromDomainStatus()));
|
||||
mailFromAttributes.put("BehaviorOnMxFailure",
|
||||
v1BehaviorToV2(identity.getBehaviorOnMxFailure()));
|
||||
if (mailFromDomain != null && !mailFromDomain.isEmpty()) {
|
||||
ObjectNode mailFromAttributes = result.putObject("MailFromAttributes");
|
||||
mailFromAttributes.put("MailFromDomain", mailFromDomain);
|
||||
mailFromAttributes.put("MailFromDomainStatus", toV2Status(identity.getMailFromDomainStatus()));
|
||||
mailFromAttributes.put("BehaviorOnMxFailure", v1BehaviorToV2(identity.getBehaviorOnMxFailure()));
|
||||
}
|
||||
|
||||
result.putObject("Policies");
|
||||
ArrayNode tags = result.putArray("Tags");
|
||||
|
||||
Reference in new issue
Block a user