diff --git a/projects/valtimo/form-view-model/src/lib/components/form-view-model/form-view-model.component.ts b/projects/valtimo/form-view-model/src/lib/components/form-view-model/form-view-model.component.ts index 6ef8a46f3..05a47c66c 100644 --- a/projects/valtimo/form-view-model/src/lib/components/form-view-model/form-view-model.component.ts +++ b/projects/valtimo/form-view-model/src/lib/components/form-view-model/form-view-model.component.ts @@ -136,11 +136,14 @@ export class FormViewModelComponent implements OnInit { const defaultOptions = { ...options, language, - ...(formioTranslations === 'object' && { - i18n: { - [language]: this.stateService.flattenTranslationsObject(formioTranslations), - }, - }), + ...(typeof formioTranslations === 'object' + ? { + language, + i18n: { + [language]: this.stateService.flattenTranslationsObject(formioTranslations), + }, + } + : {}), }; return deepmerge(defaultOptions, overrideOptions);