mirror of
https://github.com/scratchfoundation/scratch-vm.git
synced 2025-07-27 14:41:12 -04:00
Fix event listeners not being cleaned up
Eventually if you hit the green flag a million times with a "green flag => say" stack, you'd get an event emitter memory leak error.
This commit is contained in:
parent
d8a3e659d5
commit
44ca62fefc
1 changed files with 1 additions and 0 deletions
|
@ -92,6 +92,7 @@ class Scratch3LooksBlocks {
|
||||||
this.runtime.renderer.destroySkin(bubbleState.skinId);
|
this.runtime.renderer.destroySkin(bubbleState.skinId);
|
||||||
bubbleState.skinId = null;
|
bubbleState.skinId = null;
|
||||||
}
|
}
|
||||||
|
target.removeListener(RenderedTarget.EVENT_TARGET_MOVED, this._onTargetMoved);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue