remove sensitive state before sending to Sentry

This commit is contained in:
pa
2025-10-18 00:28:42 +09:00
committed by Natsumi
parent 1fcffd9267
commit bed90d211b

View File

@@ -36,7 +36,34 @@ import { useWorldStore } from './world';
import { useWristOverlaySettingsStore } from './settings/wristOverlay';
export const pinia = createPinia();
pinia.use(createSentryPiniaPlugin());
pinia.use(
createSentryPiniaPlugin({
stateTransformer: (state) => ({
...state,
Auth: null,
Feed: null,
Favorite: null,
Friend: null,
User: {
// @ts-ignore
...state.User,
currentUser: null,
subsetOfLanguages: null
},
GameLog: {
// @ts-ignore
...state.GameLog,
gameLogTable: null
},
Notification: {
// @ts-ignore
...state.Notification,
notificationTable: null
}
})
})
);
export function createGlobalStores() {
return {