[FIX] mail: prevents video access traceback after ending a call

Before this commit, it was assumed that the call was still active when
the video permission was granted, this assumption was false and this
commit fixes this issue.

closes odoo/odoo#75999

Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
This commit is contained in:
Thanh Dodeur
2021-09-06 15:47:14 +00:00
committed by Sébastien Theys
parent 0d1908e644
commit 53c6ceb909
+3
View File
@@ -795,6 +795,9 @@ function factory(dependencies) {
const sendDisplay = force !== undefined ? force : !this.sendDisplay;
await this._updateLocalVideoTrack(type, sendDisplay);
}
if (!this.currentRtcSession) {
return;
}
if (!this.videoTrack) {
this.currentRtcSession.removeVideo();
} else {