📈 Capture logout event + merge set and identify calls (#1211)

Signed-off-by: Luke Vella <me@lukevella.com>
This commit is contained in:
Luke Vella 2024-07-21 09:47:00 +01:00 committed by GitHub
parent c126cbdda1
commit ba3008b3f2
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 29 additions and 16 deletions

View file

@ -174,7 +174,6 @@ const getAuthOptions = (...args: GetServerSessionParams) =>
providers: providers,
pages: {
signIn: "/login",
signOut: "/logout",
error: "/auth/error",
},
events: {
@ -193,12 +192,6 @@ const getAuthOptions = (...args: GetServerSessionParams) =>
},
});
},
signOut({ session }) {
posthog?.capture({
distinctId: session.user.id,
event: "logout",
});
},
},
callbacks: {
async signIn({ user, email, profile }) {