Fix for ion-modal spurious blaze errors

This commit is contained in:
Joshua Ohlman 2015-02-18 13:09:51 -06:00
parent 72212890fe
commit 5d47571ac1

View file

@ -33,13 +33,16 @@ IonLoading = {
},
hide: function () {
var $loadingEl = $(this.view.firstNode());
$loadingEl.removeClass('active');
if (this.view) {
var $loadingEl = $(this.view.firstNode());
$loadingEl.removeClass('active');
Meteor.setTimeout(function () {
IonBackdrop.release();
$loadingEl.removeClass('visible');
Blaze.remove(this.view);
}.bind(this), 400);
Meteor.setTimeout(function () {
IonBackdrop.release();
$loadingEl.removeClass('visible');
Blaze.remove(this.view);
this.view = null;
}.bind(this), 400);
}
}
};