diff --git a/packages/sequence/src/sequences.service.ts b/packages/sequence/src/sequences.service.ts index f341aca..2eea54b 100644 --- a/packages/sequence/src/sequences.service.ts +++ b/packages/sequence/src/sequences.service.ts @@ -146,7 +146,7 @@ export class SequencesService implements ISequenceService { const issuedAt = toISOStringWithTimezone(date || now) const nowFiscalYear = this.getFiscalYear({ now: date || now, - registerTime: registerDate, + registerTime: registerDate ? new Date(registerDate) : undefined, startMonth, }) const sourceIp = @@ -284,6 +284,7 @@ export class SequencesService implements ISequenceService { const { now, startMonth = 4, registerTime } = options + const effectiveStartMonth = registerTime ? registerTime.getMonth() + 1 : startMonth ?? 4