Because we migrate from mixpanel to amplitude and use
the old distinct_id as a device ID, we can have situations when user ID
and device ID are set to the same value in Amplitude client.
However, the Amplitude service seems to ignore the user_id in such case.
This leads to some problems with reporting (if the same browser is used for
multiple users, we get events reported for a wrong user).
This change ensures we don't set device ID to a user ID value when we have
a choice (when multiple profiles are merged).
Change-type: patch
Signed-off-by: Roman Mazur roman@balena.io
Because we migrate from mixpanel to amplitude and use the old distinct_id as a device ID, we can have situations when user ID and device ID are set to the same value in Amplitude client.
However, the Amplitude service seems to ignore the user_id in such case. This leads to some problems with reporting (if the same browser is used for multiple users, we get events reported for a wrong user).
This change ensures we don't set device ID to a user ID value when we have a choice (when multiple profiles are merged).
Change-type: patch Signed-off-by: Roman Mazur roman@balena.io