Skip to content

Commit

Permalink
Fix #248 delete javascript reference to released media (#249)
Browse files Browse the repository at this point in the history
Co-authored-by: Nate Dudenhoeffer <[email protected]>
  • Loading branch information
AgDude and AgDude authored Apr 3, 2020
1 parent 94503df commit 3475970
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion www/Media.js
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,10 @@ Media.prototype.resumeRecord = function() {
* Release the resources.
*/
Media.prototype.release = function() {
exec(null, this.errorCallback, "Media", "release", [this.id]);
var me = this;
exec(function() {
delete mediaObjects[me.id];
}, this.errorCallback, "Media", "release", [this.id]);
};

/**
Expand Down

0 comments on commit 3475970

Please sign in to comment.