From f824c80955c967a1b28aa2231971ae7471080a4e Mon Sep 17 00:00:00 2001 From: Maarten Manders Date: Thu, 11 Mar 2021 09:40:54 +0100 Subject: [PATCH] fix: Normalized Event before caching. (#3305) --- packages/integrations/src/offline.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/integrations/src/offline.ts b/packages/integrations/src/offline.ts index 2168815a2f16..03f9949dde15 100644 --- a/packages/integrations/src/offline.ts +++ b/packages/integrations/src/offline.ts @@ -1,6 +1,6 @@ /* eslint-disable @typescript-eslint/no-unsafe-member-access */ import { Event, EventProcessor, Hub, Integration } from '@sentry/types'; -import { getGlobalObject, logger, uuid4 } from '@sentry/utils'; +import { getGlobalObject, logger, normalize, uuid4 } from '@sentry/utils'; import * as localForageType from 'localforage'; // eslint-disable-next-line @typescript-eslint/no-var-requires @@ -98,7 +98,7 @@ export class Offline implements Integration { * @param event an event */ private async _cacheEvent(event: Event): Promise { - return this.offlineEventStore.setItem(uuid4(), event); + return this.offlineEventStore.setItem(uuid4(), normalize(event)); } /**