Skip to content

Commit b935c5b

Browse files
committed
added null check for WebAudio pannerNode
1 parent f7a41b7 commit b935c5b

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

src/sound/webaudio/WebAudioSound.js

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -512,8 +512,10 @@ var WebAudioSound = new Class({
512512
this.muteNode = null;
513513
this.volumeNode.disconnect();
514514
this.volumeNode = null;
515-
this.pannerNode.disconnect();
516-
this.pannerNode = null;
515+
if (this.pannerNode) {
516+
this.pannerNode.disconnect();
517+
this.pannerNode = null;
518+
}
517519
this.rateUpdates.length = 0;
518520
this.rateUpdates = null;
519521
},

0 commit comments

Comments
 (0)