Skip to content

Commit

Permalink
The BaseSound.destroy method will now call BaseSound.stop which w…
Browse files Browse the repository at this point in the history
…ill reset the `isPlaying` and other flags. Fix #6645
  • Loading branch information
photonstorm committed Nov 8, 2023
1 parent 6796de4 commit 494ea72
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/sound/BaseSound.js
Original file line number Diff line number Diff line change
Expand Up @@ -477,6 +477,8 @@ var BaseSound = new Class({
return;
}

this.stop();

this.emit(Events.DESTROY, this);

this.removeAllListeners();
Expand Down

0 comments on commit 494ea72

Please sign in to comment.