angular2-virtual-scroll
Advanced tools
Comparing version 0.1.3 to 0.1.4
# v0.1.4 | ||
* Bug fix: ensure that onScrollListener is actually defined before removing [#25](https://github.com/rintoj/angular2-virtual-scroll/issues/25) | ||
# v0.1.3 | ||
@@ -3,0 +7,0 @@ |
@@ -35,3 +35,9 @@ "use strict"; | ||
VirtualScrollComponent.prototype.ngOnDestroy = function () { | ||
this.onScrollListener(); | ||
// Check that listener has been attached properly: | ||
// It may be undefined in some cases, e.g. if an exception is thrown, the component is | ||
// not initialized properly but destroy may be called anyways (e.g. in testing). | ||
if (this.onScrollListener !== undefined) { | ||
// this removes the listener | ||
this.onScrollListener(); | ||
} | ||
}; | ||
@@ -38,0 +44,0 @@ VirtualScrollComponent.prototype.refresh = function () { |
{ | ||
"name": "angular2-virtual-scroll", | ||
"version": "0.1.3", | ||
"version": "0.1.4", | ||
"description": "Angular 2 module for virtual -infinite- list. Supports multi-column", | ||
@@ -5,0 +5,0 @@ "main": "dist/virtual-scroll.js", |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
37401
236