add shim for localstorage