Re: [IndexedDB] Behavior of IDBObjectStore.get() and IDBObjectStore.delete() when record doesn't exist

On Mon, Nov 8, 2010 at 4:16 PM, Jonas Sicking <jonas@sicking.cc> wrote:
>>> Similar to Kris, I think worrying about 'undefined' is worrying about
>>> an edge case. Simplicity is better than trying to cove every possible
>>> edge case.
>>
>> I thought edge cases are precisely what a specification is supposed to deal
>> with.
>
> A spec can never cover 100% of all use cases. Often covering the last
> 10-20% of the use cases adds as much complexity or API surface, if not
> more, as covering the first 80-90%. The trick really is to know when
> to stop.

Oh, I should be more clear. The spec definitely needs to *define* all
edge cases though. In general the spec currently tries to very
precisely define behavior in all edge cases, including this one. I
also added a "note" pointing out this very edge case as well as
suggest using openCursor as a workaround.

If you do find other cases which are not explicitly defined, please do
file bugs or send emails to this list.

/ Jonas

Received on Tuesday, 9 November 2010 00:57:48 UTC