[whatwg] Media Stream API: What is the intended behaviour for undefined mandatory arguments?

Hi Ian and the rest of the list,

We are having a bit of discussion regarding the correct behaviour
when mandatory arguments are undefined, see this webkit bug for history:
https://bugs.webkit.org/show_bug.cgi?id=60622

Could we have some clarification for the below cases, please:

var u;
var n = null;

// Should throw since u is undefined or just abort?
navigator.webkitGetUserMedia("audio", u);

// Will not throw but will abort.
navigator.webkitGetUserMedia("audio", n);

// Should throw because we are expecting at least two arguments.
navigator.webkitGetUserMedia("audio");

Thanks in advance,
Tommy


-- 
Tommy Widenflycht, Senior Software Engineer
Google Sweden AB, Kungsbron 2, SE-11122 Stockholm, Sweden
Org. nr. 556656-6880

This email may be confidential or privileged. If you received this
communication by mistake, please don't forward it to anyone else, please
erase all copies and attachments, and please let me know that it went to the
wrong person. Thanks!
And yes, I have to include this message in every outgoing email according to
EU law.

Received on Wednesday, 1 June 2011 00:57:53 UTC