switching to local storage