RE: [indexeddb] Handling negative parameters for the advance method

> >
> > Hmm.. Yeah, I suspect that is the better behavior here. We should
> > probably also throw if the number is 0.
> >
> > / Jonas
> 
> If a developer specifies zero as a value, we could throw an
> IDBDatabaseException with a value of NON_TRANSIENT_ERR.
> What about doing the same for negative values?
> 
> Israel
> 


For cursor.advance() in sync & async, I changed "count" parameter type to long and added NON_TRANSIENT_ERR:

Exception	                                                     Description
IDBDatabaseException	NON_TRANSIENT_ERR	The value passed into the count parameter was zero or a negative number.

Thanks,

Eliot

Received on Monday, 22 August 2011 21:30:39 UTC