fix(bookkeeping): allow a first rakenskapsar shorter than 6 months (#1165)

The validator enforced a 6-month minimum on the FIRST fiscal period,
citing BFL 3 kap. The law says the opposite: BFL 3 kap 3 par expressly
allows a rakenskapsar shorter than 12 months, with no floor, when
bokforingsskyldigheten begins (Bolagsverket: the first year may be
"hur kort som helst", max 18 months). The floor only applied to
isFirstPeriod, exactly the case the law exempts, and blocked an
autumn-registered AB from shortening its first year to Dec 31 to file
an early arsredovisning.

Drop the minimum, keep the 18-month cap and the day-boundary rules,
and remove the now-dead Swedish error mapping.

Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
Jakob Wennberg
2026-07-25 11:23:18 +02:00
committed by GitHub
co-authored by Claude Fable 5
parent 98886e68d8
commit 47938520d6
5 changed files with 25 additions and 18 deletions
@@ -34,7 +34,6 @@ function toSwedishError(msg: string): string {
if (msg.includes('1st of a month')) return 'Startdatum måste vara den första i månaden.'
if (msg.includes('last day of a month')) return 'Slutdatum måste vara den sista i månaden.'
if (msg.includes('exceeds maximum 18 months')) return 'Räkenskapsåret får vara högst 18 månader (BFL 3 kap.).'
if (msg.includes('at least 6 months')) return 'Första räkenskapsåret måste vara minst 6 månader (BFL 3 kap.).'
return msg
}