From a72317484bdebd5c6dee03d0b95320f20ab9f85b Mon Sep 17 00:00:00 2001 From: Mark Buer Date: Wed, 13 Jan 2016 11:04:15 +1030 Subject: [PATCH] fixes background unbind --- imagesloaded.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/imagesloaded.js b/imagesloaded.js index b8b5dc3..c2e4413 100644 --- a/imagesloaded.js +++ b/imagesloaded.js @@ -336,8 +336,8 @@ Background.prototype.check = function() { }; Background.prototype.unbindEvents = function() { - this.img.addEventListener( 'load', this ); - this.img.addEventListener( 'error', this ); + this.img.removeEventListener( 'load', this ); + this.img.removeEventListener( 'error', this ); }; Background.prototype.confirm = function( isLoaded, message ) {