Skip to content

Commit 321f51b

Browse files
D-K-PTrigger.dev RepoOps
authored andcommitted
chore(webapp): refine PostHog reset handling
Refine when the dashboard's PostHog client resets its state. Mono-RevId: af05a826f8312ff8c468d14ffdc7a1cb12abf538
1 parent 719c8c9 commit 321f51b

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎apps/webapp/app/hooks/usePostHog.ts‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ export const usePostHog = (
5353
if (user) {
5454
if (logging) console.log("Identifying user", user);
5555
posthog.identify(user.id, { email: user.email });
56-
} else {
56+
} else if (posthog.get_property("$user_state") === "identified") {
5757
if (logging) console.log("Resetting user");
5858
posthog.reset();
5959
}

0 commit comments

Comments
 (0)