Skip to content

Commit d8a319b

Browse files
mohsinAhsanAyaz
mohsin
authored andcommitted
fix(angular-tags-input): Fix the handle key up undefined issue
1:- when select any value from down and press any key after selection it shows handleKeyUp of undefined in console. Fix the issue check the condition if dropdown has some value then handleKeyUp function calls
1 parent f102cd9 commit d8a319b

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

projects/angular-tags-input/src/lib/angular-tags-input.component.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -465,7 +465,9 @@ export class AngularTagsInputComponent implements OnInit, AfterViewInit, Control
465465
}
466466
// so we have the dropdown shown
467467
setTimeout(() => {
468-
this.dropdown.handleKeyUp($event);
468+
if (this.dropdown) {
469+
this.dropdown.handleKeyUp($event);
470+
}
469471
}, 10);
470472
}
471473

0 commit comments

Comments
 (0)