Skip to content

Commit

Permalink
decoupled mixpannel chunk
Browse files Browse the repository at this point in the history
  • Loading branch information
vsvamsi1 committed Oct 18, 2024
1 parent 9a315ea commit 9a15935
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
8 changes: 6 additions & 2 deletions app/client/src/ce/sagas/userSagas.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -209,8 +209,12 @@ export function* runUserSideEffectsSaga() {
}
}

if (!currentUser.isAnonymous && currentUser.username !== ANONYMOUS_USERNAME) {
enableTelemetry && AnalyticsUtil.identifyUser(currentUser);
if (
!currentUser.isAnonymous &&
currentUser.username !== ANONYMOUS_USERNAME &&
enableTelemetry
) {
yield AnalyticsUtil.identifyUser(currentUser);
}

const isFFFetched: boolean = yield select(getFeatureFlagsFetched);
Expand Down
4 changes: 2 additions & 2 deletions app/client/src/pages/Editor/HelpButton.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ export function IntercomConsent({
const instanceId = useSelector(getInstanceId);
const dispatch = useDispatch();

const sendUserDataToIntercom = () => {
const sendUserDataToIntercom = async () => {
const { email } = user || {};

updateIntercomProperties(instanceId, user);
Expand All @@ -115,7 +115,7 @@ export function IntercomConsent({
showIntercomConsent(false);

if (user?.enableTelemetry) {
AnalyticsUtil.identifyUser(user, true);
await AnalyticsUtil.identifyUser(user, true);
AnalyticsUtil.logEvent("SUPPORT_REQUEST_INITIATED", {
email,
});
Expand Down

0 comments on commit 9a15935

Please sign in to comment.