diff --git a/src/lib/actions/analytics.ts b/src/lib/actions/analytics.ts index e765b799f..a6f58b911 100644 --- a/src/lib/actions/analytics.ts +++ b/src/lib/actions/analytics.ts @@ -289,5 +289,5 @@ export enum Submit { SmsResetTemplate = 'submit_sms_reset_template', SmsUpdateInviteTemplate = 'submit_sms_update_invite_template', SmsUpdateLoginTemplate = 'submit_sms_update_login_template', - SmsUpdateVerificationTemplate = 'submit_sms_update_verification_template', + SmsUpdateVerificationTemplate = 'submit_sms_update_verification_template' } diff --git a/src/routes/console/project-[project]/settings/smtp/+page.svelte b/src/routes/console/project-[project]/settings/smtp/+page.svelte index b09a0f93f..6135a55a1 100644 --- a/src/routes/console/project-[project]/settings/smtp/+page.svelte +++ b/src/routes/console/project-[project]/settings/smtp/+page.svelte @@ -202,28 +202,31 @@ - showTestSMTPModal = true}> - Send test email - + (showTestSMTPModal = true)}> + Send test email + - - Update - - + + Update + + - - {#if showTestSMTPModal} - - + {/if} diff --git a/src/routes/console/project-[project]/settings/smtp/smtpTestModal.svelte b/src/routes/console/project-[project]/settings/smtp/smtpTestModal.svelte index 48a56fa88..487189442 100644 --- a/src/routes/console/project-[project]/settings/smtp/smtpTestModal.svelte +++ b/src/routes/console/project-[project]/settings/smtp/smtpTestModal.svelte @@ -31,8 +31,8 @@ async function handleTestEmail() { try { - const allMails = [ ...emails ]; - if(sendToSelf) { + const allMails = [...emails]; + if (sendToSelf) { allMails.push($user.email); } @@ -44,70 +44,68 @@ host ? host : undefined, replyTo ? replyTo : undefined, port ? port : undefined, - username ? username : undefined, + username ? username : undefined, password ? password : undefined, secure ? 'tls' : undefined - ) - close(); - if(allMails.length === 1) { - addNotification({ - type: 'success', - message: `Test email has been sent to ${allMails[0]}` - }); - } else { - addNotification({ - type: 'success', - message: `Test email has been sent to ${allMails[0]} and ${allMails.length - 1} others` - }); - - } + ); + close(); + if (allMails.length === 1) { + addNotification({ + type: 'success', + message: `Test email has been sent to ${allMails[0]}` + }); + } else { + addNotification({ + type: 'success', + message: `Test email has been sent to ${allMails[0]} and ${ + allMails.length - 1 + } others` + }); + } trackEvent(Submit.ProjectTestSMTP); } catch (e) { error = e.message; trackError(e, Submit.ProjectTestSMTP); } - } - - Send test email - + Send test email - - - sendToSelf = !sendToSelf} /> - {$user.email} - - - - sendToOthers = !sendToOthers} /> - - - Others - Enter the email address(es) to which the test message will be sent - - - - + (sendToSelf = !sendToSelf)} /> + {$user.email} - + + + (sendToOthers = !sendToOthers)} /> + + + Others + + Enter the email address(es) to which the test message will be sent + + + + +
{$user.email}
Others
Enter the email address(es) to which the test message will be sent
+ Enter the email address(es) to which the test message will be sent +