fixes localstorage