Skip to content

Rallly is an open-source scheduling and collaboration tool designed to make organizing events and meetings easier.

📈 Track space creation after user registration

Luke Vella6898df9a56cc
diff --git a/apps/web/src/trpc/routers/auth.ts b/apps/web/src/trpc/routers/auth.ts
index 656b95e74..6084c5fbf 100644
--- a/apps/web/src/trpc/routers/auth.ts
+++ b/apps/web/src/trpc/routers/auth.ts
@@ -139,8 +139,6 @@ export const auth = router({
ownerId: user.id,
});
- trackSpaceCreated({ space, userId: user.id });
-
if (ctx.user?.isGuest) {
try {
await mergeGuestsIntoUser(user.id, [ctx.user.id]);
@@ -166,6 +164,8 @@ export const auth = router({
},
});
+ trackSpaceCreated({ space, userId: user.id });
+
return {
ok: true,
user: {