refactor(sentry): unify formatting in Sentry configuration files
- Standardized indentation and formatting in `sentry.client.config.ts`, `sentry.server.config.ts`, and `sentry.edge.config.ts` for consistency.
This commit is contained in:
@@ -1,22 +1,22 @@
|
|||||||
import * as Sentry from "@sentry/nextjs";
|
import * as Sentry from "@sentry/nextjs";
|
||||||
|
|
||||||
Sentry.init({
|
Sentry.init({
|
||||||
dsn: process.env.NEXT_PUBLIC_SENTRY_DSN,
|
dsn: process.env.NEXT_PUBLIC_SENTRY_DSN,
|
||||||
|
|
||||||
// Ajustez ces valeurs en production
|
|
||||||
tracesSampleRate: 1.0,
|
|
||||||
|
|
||||||
// Replay est activé par défaut
|
|
||||||
replaysSessionSampleRate: 0.1,
|
|
||||||
replaysOnErrorSampleRate: 1.0,
|
|
||||||
|
|
||||||
integrations: [
|
// Ajustez ces valeurs en production
|
||||||
Sentry.replayIntegration({
|
tracesSampleRate: 1.0,
|
||||||
maskAllText: true,
|
|
||||||
blockAllMedia: true,
|
|
||||||
}),
|
|
||||||
],
|
|
||||||
|
|
||||||
// Protection PII
|
// Replay est activé par défaut
|
||||||
sendDefaultPii: false,
|
replaysSessionSampleRate: 0.1,
|
||||||
|
replaysOnErrorSampleRate: 1.0,
|
||||||
|
|
||||||
|
integrations: [
|
||||||
|
Sentry.replayIntegration({
|
||||||
|
maskAllText: true,
|
||||||
|
blockAllMedia: true,
|
||||||
|
}),
|
||||||
|
],
|
||||||
|
|
||||||
|
// Protection PII
|
||||||
|
sendDefaultPii: false,
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -1,11 +1,11 @@
|
|||||||
import * as Sentry from "@sentry/nextjs";
|
import * as Sentry from "@sentry/nextjs";
|
||||||
|
|
||||||
Sentry.init({
|
Sentry.init({
|
||||||
dsn: process.env.NEXT_PUBLIC_SENTRY_DSN,
|
dsn: process.env.NEXT_PUBLIC_SENTRY_DSN,
|
||||||
|
|
||||||
// Ajustez ces valeurs en production
|
|
||||||
tracesSampleRate: 1.0,
|
|
||||||
|
|
||||||
// Protection PII
|
// Ajustez ces valeurs en production
|
||||||
sendDefaultPii: false,
|
tracesSampleRate: 1.0,
|
||||||
|
|
||||||
|
// Protection PII
|
||||||
|
sendDefaultPii: false,
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -2,21 +2,21 @@ import { createHash } from "node:crypto";
|
|||||||
import * as Sentry from "@sentry/nextjs";
|
import * as Sentry from "@sentry/nextjs";
|
||||||
|
|
||||||
Sentry.init({
|
Sentry.init({
|
||||||
dsn: process.env.NEXT_PUBLIC_SENTRY_DSN,
|
dsn: process.env.NEXT_PUBLIC_SENTRY_DSN,
|
||||||
|
|
||||||
// Ajustez ces valeurs en production
|
|
||||||
tracesSampleRate: 1.0,
|
|
||||||
|
|
||||||
// Protection PII
|
// Ajustez ces valeurs en production
|
||||||
sendDefaultPii: false,
|
tracesSampleRate: 1.0,
|
||||||
|
|
||||||
beforeSend(event) {
|
// Protection PII
|
||||||
// Hachage de l'IP utilisateur pour Sentry si elle est présente
|
sendDefaultPii: false,
|
||||||
if (event.user?.ip_address) {
|
|
||||||
event.user.ip_address = createHash("sha256")
|
beforeSend(event) {
|
||||||
.update(event.user.ip_address)
|
// Hachage de l'IP utilisateur pour Sentry si elle est présente
|
||||||
.digest("hex");
|
if (event.user?.ip_address) {
|
||||||
}
|
event.user.ip_address = createHash("sha256")
|
||||||
return event;
|
.update(event.user.ip_address)
|
||||||
},
|
.digest("hex");
|
||||||
|
}
|
||||||
|
return event;
|
||||||
|
},
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in New Issue
Block a user