From f26024313af1e458c177d9b35378eaf93a246348 Mon Sep 17 00:00:00 2001 From: Dory Zidon Date: Mon, 10 Jul 2017 07:33:13 -0700 Subject: [PATCH] fixed first run issue when using default text --- src/dropdown/dropdown.component.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/dropdown/dropdown.component.ts b/src/dropdown/dropdown.component.ts index 9780f7e2..7c83a443 100644 --- a/src/dropdown/dropdown.component.ts +++ b/src/dropdown/dropdown.component.ts @@ -292,9 +292,9 @@ export class MultiselectDropdown implements OnInit, OnChanges, DoCheck, OnDestro updateTitle() { if (this.numSelected === 0 || this.settings.fixedTitle) { - this.title = this.texts.defaultTitle || ''; + this.title = (this.texts) ? this.texts.defaultTitle : ''; } else if (this.settings.displayAllSelectedText && this.model.length === this.options.length) { - this.title = this.texts.allSelected || ''; + this.title = (this.texts) ? this.texts.allSelected : ''; } else if (this.settings.dynamicTitleMaxItems && this.settings.dynamicTitleMaxItems >= this.numSelected) { this.title = this.options .filter((option: IMultiSelectOption) =>