Skip to content

Commit

Permalink
Merge pull request #671 from de-don/patch-1
Browse files Browse the repository at this point in the history
fix: correct problem with undefined instance
  • Loading branch information
KingSora authored Aug 26, 2024
2 parents b11536b + c800326 commit a2e1266
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ export class OverlayScrollbarsComponent implements OnDestroy, AfterViewInit {
}

ngOnDestroy() {
this.osDirective?.osInstance()!.destroy();
this.osDirective?.osInstance()?.destroy();
}

mergeEvents(originalEvents: OverlayScrollbarsComponent['events']) {
Expand Down

0 comments on commit a2e1266

Please sign in to comment.