added localstorage wrapper