1
0
mirror of https://github.com/matrix-org/matrix-react-sdk.git synced 2025-11-08 21:42:24 +03:00

Add identifyUser

This commit is contained in:
James Salter
2021-07-21 08:38:58 +01:00
parent 74b0e52f9a
commit 4b0cb409a0
2 changed files with 22 additions and 1 deletions

View File

@@ -64,6 +64,11 @@ export class PosthogAnalytics {
}
}
public async identifyUser(userId: string) {
if (this.onlyTrackAnonymousEvents) return;
this.posthog.identify(await hashHex(userId));
}
public isInitialised(): boolean {
return this.initialised;
}