Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
davehorton committed Nov 16, 2024
1 parent 5e7c665 commit 8711940
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion lib/call-session.js
Original file line number Diff line number Diff line change
Expand Up @@ -619,7 +619,8 @@ Duration=${payload.duration} `
const toTag = dlg.type === 'uas' ? this.rtpEngineOpts.uac.tag : this.rtpEngineOpts.uas.tag;
const reason = req.get('X-Reason');
const isReleasingMedia = reason && dlg.type === 'uac' && ['release-media', 'anchor-media'].includes(reason);
const isFullMediaRelease = isReleasingMedia && process.env.JAMBONES_ENABLE_FULL_MEDIA_RELEASE;
const isFullMediaRelease = isReleasingMedia &&
reason === 'release-media-entirely';
const offerMedia = dlg.type === 'uas' ? this.rtpEngineOpts.uac.mediaOpts : this.rtpEngineOpts.uas.mediaOpts;
const answerMedia = dlg.type === 'uas' ? this.rtpEngineOpts.uas.mediaOpts : this.rtpEngineOpts.uac.mediaOpts;
const direction = dlg.type === 'uas' ? ['public', 'private'] : ['private', 'public'];
Expand Down Expand Up @@ -697,6 +698,7 @@ Duration=${payload.duration} `
this.rtpEngineResource.destroy().catch((err) => {
this.logger.info({err}, 'Error destroying rtpengine resource after full media release');
});
this._fullMediaReleased = true;
return;
}

Expand Down

0 comments on commit 8711940

Please sign in to comment.