From 3a956919b273aa536df2cd0422636ab36f492bc8 Mon Sep 17 00:00:00 2001 From: Julian Krauser Date: Thu, 17 Apr 2025 13:41:04 +0200 Subject: [PATCH] hotfix: template backup restore --- src/helpers/backupHelper.ts | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/helpers/backupHelper.ts b/src/helpers/backupHelper.ts index a9f8dbf..319a298 100644 --- a/src/helpers/backupHelper.ts +++ b/src/helpers/backupHelper.ts @@ -755,11 +755,11 @@ export default abstract class BackupHelper { .filter((d) => availableTemplates.includes(d.scope)) .map((d) => ({ ...d, - headerHeightId: templates.find((template) => template.template == d.headerHeight.template)?.id ?? null, - footerHeightId: templates.find((template) => template.template == d.footerHeight.template)?.id ?? null, - headerId: templates.find((template) => template.template == d.header.template)?.id ?? null, - bodyId: templates.find((template) => template.template == d.body.template)?.id ?? null, - footerId: templates.find((template) => template.template == d.footer.template)?.id ?? null, + headerHeightId: templates.find((template) => template.template == d.headerHeight)?.id ?? null, + footerHeightId: templates.find((template) => template.template == d.footerHeight)?.id ?? null, + headerId: templates.find((template) => template.template == d.header?.template)?.id ?? null, + bodyId: templates.find((template) => template.template == d.body?.template)?.id ?? null, + footerId: templates.find((template) => template.template == d.footer?.template)?.id ?? null, })); availableTemplates.forEach((at) => { if (!dataWithMappedId.some((d) => d.scope == at)) {