Merge from Develop for Monitor production release #3
|
@ -122,7 +122,9 @@ export class PageContentComponent implements OnInit, AfterViewInit, OnDestroy {
|
||||||
|
|
||||||
ngOnDestroy() {
|
ngOnDestroy() {
|
||||||
this.subscriptions.forEach(subscription => {
|
this.subscriptions.forEach(subscription => {
|
||||||
if (subscription instanceof (ResizeObserver || IntersectionObserver)) {
|
if (typeof ResizeObserver !== "undefined" && subscription instanceof ResizeObserver) {
|
||||||
|
subscription.disconnect();
|
||||||
|
} else if (typeof ResizeObserver !== "undefined" && subscription instanceof IntersectionObserver) {
|
||||||
subscription.disconnect();
|
subscription.disconnect();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
|
@ -85,7 +85,7 @@ export class LayoutService {
|
||||||
this.subscriptions.forEach(subscription => {
|
this.subscriptions.forEach(subscription => {
|
||||||
if (subscription instanceof Subscriber) {
|
if (subscription instanceof Subscriber) {
|
||||||
subscription.unsubscribe();
|
subscription.unsubscribe();
|
||||||
} else if (subscription instanceof ResizeObserver) {
|
} else if (typeof ResizeObserver !== "undefined" && subscription instanceof ResizeObserver) {
|
||||||
subscription.disconnect();
|
subscription.disconnect();
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
Loading…
Reference in New Issue