From b768ba6674dd72a5956e4596e39d3b91efd3db3e Mon Sep 17 00:00:00 2001 From: abhishek-K-P Date: Thu, 25 Jul 2024 10:47:33 +0530 Subject: [PATCH] bug fix for about us --- .../content-toc/app-toc-about/app-toc-about.component.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/library/ws-widget/collection/src/lib/_common/content-toc/app-toc-about/app-toc-about.component.ts b/library/ws-widget/collection/src/lib/_common/content-toc/app-toc-about/app-toc-about.component.ts index 16804cbaa..605d36a24 100644 --- a/library/ws-widget/collection/src/lib/_common/content-toc/app-toc-about/app-toc-about.component.ts +++ b/library/ws-widget/collection/src/lib/_common/content-toc/app-toc-about/app-toc-about.component.ts @@ -189,7 +189,7 @@ export class AppTocAboutComponent implements OnInit, OnChanges, AfterViewInit, O this.loadCompetencies() } - if (this.content && this.content.contentId.includes('ext_')) { + if (this.content && this.content.contentId && this.content.contentId.includes('ext_')) { this.loadCompetencies() } @@ -217,7 +217,7 @@ export class AppTocAboutComponent implements OnInit, OnChanges, AfterViewInit, O if (this.descElem.nativeElement.offsetHeight > 72) { this.description.ellipsis = true } - if (this.objectivesElem.nativeElement.offsetHeight > 72) { + if (this.objectivesElem && this.objectivesElem.nativeElement.offsetHeight > 72) { this.objectives.ellipsis = true } } else { @@ -228,7 +228,7 @@ export class AppTocAboutComponent implements OnInit, OnChanges, AfterViewInit, O if (this.descElem.nativeElement.offsetHeight > 48) { this.description.ellipsis = true } - if (this.objectivesElem.nativeElement.offsetHeight > 48) { + if (this.objectivesElem && this.objectivesElem.nativeElement.offsetHeight > 48) { this.objectives.ellipsis = true } }