From 4f4215ced52fc4179058c350545bfaea7ee8bfff Mon Sep 17 00:00:00 2001 From: Severin Opel Date: Mon, 12 Aug 2019 10:04:03 +0200 Subject: [PATCH] Close callbacks on Scatter are now removed on close. --- lib/scatter.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lib/scatter.js b/lib/scatter.js index b841647..403c095 100644 --- a/lib/scatter.js +++ b/lib/scatter.js @@ -371,6 +371,7 @@ export class AbstractScatter extends Throwable { close() { this._callCloseCallbacks() + this._removeCallbacks() this._removeSelfFromScatterContainer() } @@ -380,6 +381,10 @@ export class AbstractScatter extends Throwable { } } + _removeCallbacks(){ + this.onClose = [] + } + _removeSelfFromScatterContainer() { /** Removes self from container when it's closed.