Destroying removed sound in remove method

This commit is contained in:
Pavle Goloskokovic 2018-01-06 17:49:42 +01:00
parent 39a5c2907f
commit 89ad4f1b39

View file

@ -187,6 +187,7 @@ var BaseSoundManager = new Class({
remove: function (sound) {
var index = this.sounds.indexOf(sound);
if (index !== -1) {
sound.destroy();
this.sounds.splice(index, 1);
return true;
}