superfeedr/indexeddb-backbonejs-adapter — pull request #9 by jebu (2012-08-23 05:08:50+00:00)
Title: store.add and store.put calls fail when store has a keyPath specified

as per spec of store.add and store.put [http://www.w3.org/TR/IndexedDB/#widl-IDBObjectStore-add-IDBRequest-any-value-any-key]

"this method throws a DOMException of type DataError:

The object store uses in-line keys and the key parameter was provided."

This fixes the add and put calls to conditionally provide the key parameter after checking store.keyPath