FEATURE: analytics client now scrape user email and room group
This commit is contained in:
@@ -19,10 +19,10 @@ class AnalyticsClient {
|
||||
}
|
||||
}
|
||||
|
||||
identifyUser(uuid: string) {
|
||||
identifyUser(uuid: string, email: string | null) {
|
||||
this.posthogPromise
|
||||
.then((posthog) => {
|
||||
posthog.identify(uuid, { uuid, wa: true });
|
||||
posthog.identify(uuid, { uuid, email, wa: true });
|
||||
})
|
||||
.catch();
|
||||
}
|
||||
@@ -43,10 +43,10 @@ class AnalyticsClient {
|
||||
.catch();
|
||||
}
|
||||
|
||||
enteredRoom(roomId: string) {
|
||||
enteredRoom(roomId: string, roomGroup: string | null) {
|
||||
this.posthogPromise
|
||||
.then((posthog) => {
|
||||
posthog.capture("$pageView", { roomId });
|
||||
posthog.capture("$pageView", { roomId, roomGroup });
|
||||
})
|
||||
.catch();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user