fix: only allow sending email if to is set

This commit is contained in:
Shariq Ansari 2025-03-22 15:46:34 +05:30
parent 7b108f945d
commit c4a1abb6b9

View File

@ -175,7 +175,11 @@ const commentEmpty = computed(() => {
}) })
const emailEmpty = computed(() => { const emailEmpty = computed(() => {
return !newEmail.value || newEmail.value === '<p></p>' return (
!newEmail.value ||
newEmail.value === '<p></p>' ||
!newEmailEditor.value?.toEmails?.length
)
}) })
async function sendMail() { async function sendMail() {