@dibs-tech/mail-client
Advanced tools
Comparing version 1.9.2 to 1.9.3
@@ -207,2 +207,3 @@ const SparkPost = require('sparkpost'); | ||
let template = `white-label/${whiteLabelTemplateMap[emailType]}`; | ||
let customEmailText = ''; | ||
if (studio.custom_email_template) { | ||
@@ -212,2 +213,3 @@ switch (emailType) { | ||
template = studio.custom_email_template.waitlisted.link; | ||
customEmailText = studio.custom_email_text && studio.custom_email_text.find(cet => cet.template === 'waitlist') && studio.custom_email_text.find(cet => cet.template === 'waitlist').text || ''; | ||
break; | ||
@@ -217,2 +219,3 @@ | ||
template = studio.custom_email_template.waitlistConfirm.link; | ||
customEmailText = studio.custom_email_text && studio.custom_email_text.find(cet => cet.template === 'confirmation') && studio.custom_email_text.find(cet => cet.template === 'confirmation').text || ''; | ||
break; | ||
@@ -229,2 +232,6 @@ | ||
case MailClient.EmailTypes.BOOKING_CONFIRMATION: | ||
template = studio.custom_email_template.confirmation.link; | ||
customEmailText = studio.custom_email_text && studio.custom_email_text.find(cet => cet.template === 'confirmation') && studio.custom_email_text.find(cet => cet.template === 'confirmation').text || ''; | ||
break; | ||
default: | ||
@@ -236,4 +243,2 @@ template = studio.custom_email_template.confirmation.link; | ||
const domain = studio.customSendingDomain || 'no-reply@ondibs.com'; | ||
const customEmailText = (studio.custom_email_text && studio.custom_email_text.find(cet => cet.template === emailType) && | ||
studio.custom_email_text.find(cet => cet.template === emailType).text) || ''; | ||
const purchasePlaceLink = studio.live && !studio.liveWidget ? 'https://www.ondibs.com/users' : `http://${studio.domain}?dibs_open`; | ||
@@ -240,0 +245,0 @@ return { |
{ | ||
"name": "@dibs-tech/mail-client", | ||
"version": "1.9.2", | ||
"version": "1.9.3", | ||
"description": "A mail client implementation, using sparkpost", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
16234
366