From 6318df549bc3dc0f18463109d33372ba1e41d4f2 Mon Sep 17 00:00:00 2001 From: Sofia <131170700+sofiaIvarsRitense@users.noreply.github.com> Date: Tue, 23 Apr 2024 16:01:42 +0200 Subject: [PATCH] Fixed object type title didn't load on page switch (#950) --- .../src/lib/components/object-list/object-list.component.ts | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/projects/valtimo/object/src/lib/components/object-list/object-list.component.ts b/projects/valtimo/object/src/lib/components/object-list/object-list.component.ts index 3135db804..79b1aa161 100644 --- a/projects/valtimo/object/src/lib/components/object-list/object-list.component.ts +++ b/projects/valtimo/object/src/lib/components/object-list/object-list.component.ts @@ -54,8 +54,7 @@ export class ObjectListComponent { readonly objectManagementId$: Observable = this.route.params.pipe( map(params => params.objectManagementId), tap(objectManagementId => { - if (!this._settingPageTitle && objectManagementId) { - this._settingPageTitle = true; + if (objectManagementId) { this.objectManagementService.getObjectById(objectManagementId).subscribe(objectType => { if (objectType.title) { this.pageTitleService.setCustomPageTitle(objectType.title); @@ -234,8 +233,6 @@ export class ObjectListComponent { }) ); - private _settingPageTitle = false; - constructor( private readonly objectService: ObjectService, private readonly objectColumnService: ObjectColumnService,