mirror of
https://github.com/signalwire/freeswitch.git
synced 2025-04-13 07:45:26 +00:00
FS-9469
added onGrant/onDenied callbacks in onStream/onError of RTCCallbacks so client code gets notified of webrtc permission change immediately remove whitespace changes
This commit is contained in:
parent
160e8f12c0
commit
5a0e1af5d6
@ -2010,10 +2010,18 @@
|
||||
};
|
||||
|
||||
RTCcallbacks.onStream = function(rtc, stream) {
|
||||
if (dialog.verto.options.permissionCallback &&
|
||||
typeof dialog.verto.options.permissionCallback.onGranted === 'function'){
|
||||
dialog.verto.options.permissionCallback.onGranted();
|
||||
}
|
||||
console.log("stream started");
|
||||
};
|
||||
|
||||
RTCcallbacks.onError = function(e) {
|
||||
if (dialog.verto.options.permissionCallback &&
|
||||
typeof dialog.verto.options.permissionCallback.onDenied === 'function'){
|
||||
dialog.verto.options.permissionCallback.onDenied();
|
||||
}
|
||||
console.error("ERROR:", e);
|
||||
dialog.hangup({cause: "Device or Permission Error"});
|
||||
};
|
||||
|
Loading…
x
Reference in New Issue
Block a user