added optional callback to setItem

i have a small program that uses [async](https://github.com/caolan/async)'s eachSeries( and eachLimit) helpers, and I am trying to persist the results to disk, both of these provide a callback, like a next() or done() when iteration is over, and I wanted to guarantee that each file is being persisted before the program exits.

with this change I can 
```
localStorage.setItem(key, json, next) 
```

Thanks