Don't run where indexedDB is not available

For example iOS - this was breaking my phonegap app
Merge pull request #22 from gwynjudd/fix-ios

Don't run where indexedDB is not available