From 0c13e7558ccb1a3abf159b335a5ba4036f168da5 Mon Sep 17 00:00:00 2001 From: Samir Date: Tue, 14 Nov 2017 23:33:41 +0600 Subject: [PATCH] audio context close --- pcm-player.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/pcm-player.js b/pcm-player.js index 15872d6..eb5a73f 100644 --- a/pcm-player.js +++ b/pcm-player.js @@ -81,6 +81,8 @@ PCMPlayer.prototype.destroy = function() { clearInterval(this.interval); } this.samples = null; + this.audioCtx.close(); + this.audioCtx = null; }; PCMPlayer.prototype.flush = function() {