The minimalistic document archiving platform.
feat(auth): enhance user signup logging with email capture (#579)
Corentin Thomasset655a1c547536
diff --git a/apps/papra-server/src/modules/app/auth/auth.services.ts b/apps/papra-server/src/modules/app/auth/auth.services.tsindex f944cf74..398901bc 100644--- a/apps/papra-server/src/modules/app/auth/auth.services.ts+++ b/apps/papra-server/src/modules/app/auth/auth.services.ts@@ -74,9 +74,9 @@ export function getAuth({databaseHooks: {user: {create: {- after: async (user) => {- logger.info({ userId: user.id }, 'User signed up');- trackingServices.captureUserEvent({ userId: user.id, event: 'User signed up' });+ after: async ({ id: userId, email }) => {+ logger.info({ userId }, 'User signed up');+ trackingServices.captureUserEvent({ userId, event: 'User signed up', properties: { $set: { email } } });},},},