Closed ryanburnette closed 10 years ago
It might be more intuitive if you get a return of false or an error object if you try to create on something that isn't a valid storage object.
I had a typo in my code and it took me a while to track it down because I didn't get an error I expected.
var foo = JsonStorage.create("localStorage");
Silly me. I had quotes around localStorage. I fixed the problem but it took me a bit to track it down. If an error was raised I'd have known faster.
localStorage
I decided to throw an exception since there's no way you can use the library without having a valid DOM Storage API thingy.
Fixed in 9cdcdf98d9d73d60907eaa94afe20ee81e159014
It might be more intuitive if you get a return of false or an error object if you try to create on something that isn't a valid storage object.
I had a typo in my code and it took me a while to track it down because I didn't get an error I expected.
Silly me. I had quotes around
localStorage
. I fixed the problem but it took me a bit to track it down. If an error was raised I'd have known faster.