Skip to content

Infisical is the open-source platform for securing secrets, certificates, access, and AI Agents.

guard getTelemetryDistinctId

Matheus Nogueira53e30fa6cb78
diff --git a/backend/src/server/plugins/error-handler.ts b/backend/src/server/plugins/error-handler.ts
index c6d80d1276..02b9580dde 100644
--- a/backend/src/server/plugins/error-handler.ts
+++ b/backend/src/server/plugins/error-handler.ts
@@ -90,7 +90,7 @@ export const fastifyErrHandler = fastifyPlugin(async (server: FastifyZodProvider
orgId: req.auth?.orgId,
realIp: req.realIp,
actor: req.auth?.actor,
- actorId: getTelemetryDistinctId(req),
+ actorId: req.auth ? getTelemetryDistinctId(req) : undefined,
details: (error as { details?: unknown }).details
},
`client error: ${error.name}`