From 2dcb53800735383575ac75a97d1a1e4acc1b92b9 Mon Sep 17 00:00:00 2001 From: Thomas Kaul <4159106+dtslvr@users.noreply.github.com> Date: Sat, 1 Aug 2026 22:05:01 +0200 Subject: [PATCH] Fix persistence of empty comment --- apps/client/eslint.config.cjs | 1 + .../create-or-update-account-dialog.component.ts | 2 +- .../create-or-update-activity-dialog.component.ts | 2 +- 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/apps/client/eslint.config.cjs b/apps/client/eslint.config.cjs index 9aff0a032d..549f7f058f 100644 --- a/apps/client/eslint.config.cjs +++ b/apps/client/eslint.config.cjs @@ -52,6 +52,7 @@ module.exports = [ 'error', { ignorePrimitives: { + boolean: true, string: true } } diff --git a/apps/client/src/app/pages/accounts/create-or-update-account-dialog/create-or-update-account-dialog.component.ts b/apps/client/src/app/pages/accounts/create-or-update-account-dialog/create-or-update-account-dialog.component.ts index 8b0536ebfa..da6125fba3 100644 --- a/apps/client/src/app/pages/accounts/create-or-update-account-dialog/create-or-update-account-dialog.component.ts +++ b/apps/client/src/app/pages/accounts/create-or-update-account-dialog/create-or-update-account-dialog.component.ts @@ -198,7 +198,7 @@ export class GfCreateOrUpdateAccountDialogComponent { protected async onSubmit() { const account: CreateAccountDto | UpdateAccountDto = { balance: this.accountForm.get('balance')?.value, - comment: this.accountForm.get('comment')?.value ?? null, + comment: this.accountForm.get('comment')?.value || null, currency: this.accountForm.get('currency')?.value, id: this.accountForm.get('accountId')?.value, name: this.accountForm.get('name')?.value, diff --git a/apps/client/src/app/pages/portfolio/activities/create-or-update-activity-dialog/create-or-update-activity-dialog.component.ts b/apps/client/src/app/pages/portfolio/activities/create-or-update-activity-dialog/create-or-update-activity-dialog.component.ts index 632db1cd41..dcd47c6c2a 100644 --- a/apps/client/src/app/pages/portfolio/activities/create-or-update-activity-dialog/create-or-update-activity-dialog.component.ts +++ b/apps/client/src/app/pages/portfolio/activities/create-or-update-activity-dialog/create-or-update-activity-dialog.component.ts @@ -471,7 +471,7 @@ export class GfCreateOrUpdateActivityDialogComponent { accountId: this.activityForm.get('accountId')?.value, assetClass: this.activityForm.get('assetClass')?.value, assetSubClass: this.activityForm.get('assetSubClass')?.value, - comment: this.activityForm.get('comment')?.value ?? null, + comment: this.activityForm.get('comment')?.value || null, currency: this.activityForm.get('currency')?.value, customCurrency: this.activityForm.get('currencyOfUnitPrice')?.value, dataSource: ['FEE', 'INTEREST', 'LIABILITY', 'VALUABLE'].includes(