connect and store users to localstorage