Fix an issue on reminder recipients when all recipients are deleted on an update

This commit is contained in:
Carlos Monastyrski
2025-08-01 11:47:49 -03:00
parent 55e5360dd4
commit 14ffa59530
@@ -42,7 +42,7 @@ export const reminderServiceFactory = ({
const $manageReminderRecipients = async (reminderId: string, newRecipients?: string[] | null): Promise<void> => { const $manageReminderRecipients = async (reminderId: string, newRecipients?: string[] | null): Promise<void> => {
if (!newRecipients || newRecipients.length === 0) { if (!newRecipients || newRecipients.length === 0) {
// If no recipients provided, remove all existing recipients // If no recipients provided, remove all existing recipients
await reminderRecipientDAL.deleteById(reminderId); await reminderRecipientDAL.delete({ reminderId });
return; return;
} }