aaronpowell / db.js

db.js is a wrapper for IndexedDB to make it easier to work against
http://aaronpowell.github.com/db.js/
MIT License
818 stars 142 forks source link

Promise catching #175

Closed brettz9 closed 8 years ago

brettz9 commented 8 years ago

Hi Aaron,

I've got quite a large number of changes here, but I think they are a bit interrelated (mostly on the theme of yet more comprehensive promise rejection, validation, and ensuring Firefox can now pass all tests; the bad-args.js test file gives a practical indication of what can be caught, some of which were not catchable before).

Below is a detailed summary of all of the changes in this PR. There is slightly less detail in the updated CHANGES file (avoiding mention of very minor or relatively inconsequential internal refactoring changes which I nevertheless mention below).

There were a few refactoring changes which may make it appear larger than it was though, such as switching to const/let.

Note that I tried to be conservative in extending testing timeouts for Firefox, only adding it where it was noted as necessary as per my testing results.

I was also conservative in adding try-catch blocks for the hard (but catchable) errors I could replicate, but I tried to be fairly thorough, but I may have missed some of these.

Here are the changes:

brettz9 commented 8 years ago

I know there is a lot here, but can I ask when u think u may find some time to review? Thanks!