W3C home > Mailing lists > Public > public-webapps@w3.org > January to March 2011

Re: [Bug 11348] New: [IndexedDB] Overhaul of the event model

From: Jeremy Orlow <jorlow@chromium.org>
Date: Fri, 11 Feb 2011 11:45:46 -0800
Message-ID: <AANLkTi=XbmB1JP14BuiHit1f77pCAR3BS+XLz0XzyiD0@mail.gmail.com>
To: Jonas Sicking <jonas@sicking.cc>
Cc: ben turner <bent.mozilla@gmail.com>, public-webapps@w3.org
On Fri, Feb 11, 2011 at 11:38 AM, Jonas Sicking <jonas@sicking.cc> wrote:

> On Fri, Feb 11, 2011 at 11:30 AM, ben turner <bent.mozilla@gmail.com>
> wrote:
> > It looks like I was wrong. Our current impl throws NOT_ALLOWED_ERR for
> > getting errorCode *and* result before readyState is set to DONE.
> >
> > And now that I think about it I think I like that best. If we returned
> > NO_ERR from errorCode before DONE then it seems to imply that the
> > request succeeded when the reality is we don't yet know. Checking
> > errorCode before DONE is most likely a bug in the page script just as
> > calling result before DONE, so I'm happy with throwing here.
> >
> > Sound ok?
>
> Ah, I thought that's what you were saying in your previous email :-)
>
> I.e. throw when it's almost surely a bug in the script (reading too
> early), and return 0/undefined once there is a result of some sort.
>
> Sounds ok to me.
>

Sounds good to me.

J
Received on Friday, 11 February 2011 19:47:04 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 18:49:43 GMT