mirror of
https://github.com/HabitRPG/habitica.git
synced 2025-12-18 15:17:25 +01:00
fix(analytics): send user on reg (#8044)
Also fixes an issue that could prevent item name data from being correctly sent to Amplitude.
This commit is contained in:
@@ -155,6 +155,7 @@ api.registerLocal = {
|
|||||||
gaLabel: 'local',
|
gaLabel: 'local',
|
||||||
uuid: savedUser._id,
|
uuid: savedUser._id,
|
||||||
headers: req.headers,
|
headers: req.headers,
|
||||||
|
user: savedUser,
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -144,7 +144,7 @@ let _formatDataForAmplitude = (data) => {
|
|||||||
let itemName = _lookUpItemName(data.itemKey);
|
let itemName = _lookUpItemName(data.itemKey);
|
||||||
|
|
||||||
if (itemName) {
|
if (itemName) {
|
||||||
event_properties.itemName = itemName;
|
ampData.event_properties.itemName = itemName;
|
||||||
}
|
}
|
||||||
return ampData;
|
return ampData;
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user