In my index.html i have the following code to display a tidio live chat. This sets the name as a guest as they haven't logged in before. (that works)
<script
src="tidio link"
async
></script>
<script>
document.tidioIdentify = {
name: "Guest", // Visitor name
};
</script>
However, once they do login i want to get their logged in name. i have added this code to the html on the homepage (separate html from above) like this:
<script>
tidioChatApi.setVisitorData({
name: "bob",
});
</script>
However, it is never updating the name. Does anyone know why? The script doesn't seem to be getting called