Skip to content

Commit

Permalink
Fix apache#248 delete javascript reference to released media (apache#249
Browse files Browse the repository at this point in the history
)

Co-authored-by: Nate Dudenhoeffer <agdude@users.noreply.github.com>
  • Loading branch information
2 people authored and uaza committed Oct 22, 2020
1 parent 490b222 commit eb8c171
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion www/Media.js
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 eb8c171

Please sign in to comment.