mirror of
https://github.com/documenso/documenso.git
synced 2025-11-18 02:32:00 +10:00
fix: additional backwards compat
This commit is contained in:
@ -14,7 +14,7 @@ import {
|
||||
} from '../../types/document-auth';
|
||||
import { nanoid } from '../../universal/id';
|
||||
import { createRecipientAuthOptions } from '../../utils/document-auth';
|
||||
import type { EnvelopeIdOptions } from '../../utils/envelope';
|
||||
import { type EnvelopeIdOptions, mapSecondaryIdToTemplateId } from '../../utils/envelope';
|
||||
import { getEnvelopeWhereInput } from '../envelope/get-envelope-by-id';
|
||||
|
||||
export type SetTemplateRecipientsOptions = {
|
||||
@ -211,6 +211,10 @@ export const setTemplateRecipients = async ({
|
||||
});
|
||||
|
||||
return {
|
||||
recipients: [...filteredRecipients, ...persistedRecipients],
|
||||
recipients: [...filteredRecipients, ...persistedRecipients].map((recipient) => ({
|
||||
...recipient,
|
||||
documentId: null,
|
||||
templateId: mapSecondaryIdToTemplateId(envelope.secondaryId),
|
||||
})),
|
||||
};
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user