mirror of
https://github.com/photonstorm/phaser
synced 2024-11-26 22:52:14 +00:00
BaseSoundManager.forEachActiveSound
will now only invoke the callback if the sound actually exists and isn't pending removal. Fix #3383
This commit is contained in:
parent
718f8acf29
commit
89c30fe42f
1 changed files with 1 additions and 1 deletions
|
@ -505,7 +505,7 @@ var BaseSoundManager = new Class({
|
|||
|
||||
this.sounds.forEach(function (sound, index)
|
||||
{
|
||||
if (!sound.pendingRemove)
|
||||
if (sound && !sound.pendingRemove)
|
||||
{
|
||||
callback.call(scope || _this, sound, index, _this.sounds);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue