Closed IagoLast closed 7 years ago
CreateOffer does not support the Promises API in the plugin. Please use the callback style call: pc.createOffer(successCb, failureCb, constraints)
@johache Will there be any support for promises in the future? Seems like callbacks will eventually be removed. https://developer.mozilla.org/en-US/docs/Web/API/RTCPeerConnection/setLocalDescription
On another note, if we utilize the callback variations of the APIs on browsers that already natively support WebRTC (Chrome, Firefox, e.g ones that don't require the plugin), my understanding is that adapter.js will ensure the methods still function as intended even after the deprecated versions are completely removed from the WebRTC API, correct?
We have not yet found a good way to support promise based functions. This is something that we regularly come back to, but if we are to do it, we want to do it right.
Regarding Chrome, FF etc, we only embed Google's webrtc/adapter. Assuming they maintain support for callback prototypes, then no problem. If they don't, we will have to consider supporting that ourself.
This code snippet allows to reproduce the issue, open it on a browser and click the button.
The "select media device" dialog is shown and after allowing the following error is logged:
Error: Error calling method on NPObject
Code:
Safari: 9.2.1 OS: El Capitan 10.11.6