If an error happens in `set`, still check before calling the callback

This may cause the whole app to crash as a callback simply might be unset for `cache.set()`.
Merge pull request #35 from simpleTechs/patch-1

If an error happens in `set`, still check before calling the callback