Fixed localstorage issue