- From: Chris Prince <cprince@google.com>
- Date: Mon, 26 May 2008 13:04:19 -0700
I think the spec is technically correct. What's confusing is that the same line can mean two different things: // Start with no databases. // On the 1st call, this line means "create a database, // and set the version string to the empty string". var db1 = window.openDatabase("foo", "", "", ""); // On the 2nd call, the meaning has changed to // "open the 'foo' database, regardless of the version string". var db2 = window.openDatabase("foo", "", "", ""); On Mon, May 26, 2008 at 12:22 PM, Aaron Boodman <aa at google.com> wrote: > Quick thing. I don't think the spec makes it clear whether it is > allowed to do this: > > var db1 = window.openDatabase("foo", "", "", ""); > var db2 = window.openDatabase("foo", "1", "", ""); > > I think the answer should be "no". Thoughts? > > If so, perhaps edit this sentence: > > If the database version provided is not the empty string, and the > database already exists but has a different version, then the method > must raise an INVALID_STATE_ERR exception. > > To read like this: > > If the database version provided is not the empty string, and the > database already exists but has a different version, or no version, > then the method must raise an INVALID_STATE_ERR exception. > > - a >
Received on Monday, 26 May 2008 13:04:19 UTC