fixing localstorage