save user data to localStorage