I'm seeing some weird behavior. I’m using nothing at all except identify in js ($email, no $id) and updateProfile on the backend.
- Create a new user first@email.com. That user is added to Klaviyo via identify in js using $email and not $id.
- The user shows up in Klaviyo as expected
- Change the email address. I get Klaviyo’s internal id for the user via a search for the email address. Then I call updateProfile with the internal id retrieved and update nothing but the email address, i.e. second@email.com
- Klaviyo shows the user renamed to second@email.com
- Browse to another page. Identify js passes in second@email.com
- Klaviyo creates a new profile for first@email.com
- After that, it’s all second@email.com, but first@email.com is still left over as a duplicate from step 5/6.
To recap: The updateProfile is working as expected, but the very next js identify is somehow recreating the previous email address even though I’m supplying the new email address to it. It's like the identify call insists on using the old email address just one last time.
Any help would be appreciated.