adding localstorage support