resolveMultipleInstances
Function: resolveMultipleInstances()
resolveMultipleInstances(
instances,templatesMap,exceptionsMap,logger):ResolvedRecurringEventInstance[]
Defined in: src/services/eventGeneration/instanceResolver.ts:161
Resolves multiple generated instances in a batch operation to improve performance. This function iterates through a list of instances and applies the inheritance and exception logic to each one.
Parameters
instances
object[]
An array of generated instances to resolve.
templatesMap
Map<string, EventTemplateWithAttachments>
A map of base event templates, keyed by their IDs.
exceptionsMap
Map<string, { createdAt: Date; creatorId: string | null; exceptionData: unknown; id: string; organizationId: string; recurringEventInstanceId: string; updatedAt: Date | null; updaterId: string | null; }>
A map of event exceptions, keyed by a composite key.
logger
FastifyBaseLogger
The logger for logging warnings or errors.
Returns
ResolvedRecurringEventInstance[]
- An array of fully resolved generated event instances.