Re: [Bug 26577] New: imageCaptureError attribute shouldn't be nun-null.

On 8/14/14 2:35 AM, bugzilla@jessica.w3.org wrote:
> [Constructor(DOMString type, optional ImageCaptureErrorEventInit
> imageCaptureErrorInitDict)]
> interface ImageCaptureErrorEvent : Event {
>      readonly    attribute ImageCaptureError imageCaptureError;
> };
>
> How could imageCaptureError be non-null if imageCaptureErrorInitDict is
> optional?

I assume you mean non-nullABLE. Is your point that it needs to be:

     readonly    attribute ImageCaptureError? imageCaptureError;

or there's a question what the value is when constructed without ImageCaptureErrorEventInit?

We're inconsistent at least.  I had the opposite question [1] a while back on MediaStreamEvent where the attribute IS nullable, but I came around when I found the alternatives more complicated.

So +1 on making it nullable.

.: Jan-Ivar :.

[1] http://lists.w3.org/Archives/Public/public-webrtc/2014Jul/0015.html

Received on Friday, 15 August 2014 03:17:52 UTC