Skip to content

Commit e850512

Browse files
committed
allow boolean values for html in bulk email api as well
1 parent 09cc112 commit e850512

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

apps/web/src/server/public-api/api/emails/batch-email.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,10 @@ function sendBatch(app: PublicAPIApp) {
5353
> = emailPayloads.map((payload) => ({
5454
...payload,
5555
text: payload.text ?? undefined,
56-
html: payload.html ?? undefined,
56+
html:
57+
payload.html && payload.html !== "true" && payload.html !== "false"
58+
? payload.html
59+
: undefined,
5760
teamId: team.id,
5861
apiKeyId: team.apiKeyId,
5962
}));

0 commit comments

Comments
 (0)