fix: issue of missing user_id on welcome page events (#828)

This commit is contained in:
Shahbaz Shabbir
2023-04-10 17:15:03 +05:00
committed by GitHub
parent 0a6432c393
commit d54fdbf84f

View File

@@ -70,11 +70,11 @@ const ProgressiveProfiling = (props) => {
}, [DASHBOARD_URL, registrationResponse]);
useEffect(() => {
if (registrationResponse && authenticatedUser?.userId) {
if (ready && authenticatedUser?.userId) {
identifyAuthenticatedUser(authenticatedUser.userId);
sendPageEvent('login_and_registration', 'welcome');
}
}, [authenticatedUser, registrationResponse]);
}, [authenticatedUser, ready]);
useEffect(() => {
if (registrationResponse && authenticatedUser?.userId) {