fixed some localstorage stuff