- From: Martin Thomson <martin.thomson@gmail.com>
- Date: Tue, 7 Oct 2014 15:23:07 -0700
- To: Adam Bergkvist <adam.bergkvist@ericsson.com>
- Cc: Harald Alvestrand <harald@alvestrand.no>, "public-media-capture@w3.org" <public-media-capture@w3.org>
On 6 October 2014 23:28, Adam Bergkvist <adam.bergkvist@ericsson.com> wrote: > There's one point above that says "navigator.getUserMedia has callbacks". > Should this be reflected in the document, and if so, how? I believe that navigator.getUserMedia should be defined as being equivalent to: navigator.getUserMedia = function(constraints, successCallback, failureCallback) { let result = navigator.mediaDevices.getUserMedia(constraints); result.then(successCallback, failureCallback); return result; } This removes successCallback and failureCallback from the promise chain, but it also ensures that you don't get any weird problems when the callbacks return promises, or throw exceptions.
Received on Tuesday, 7 October 2014 22:23:34 UTC