From a59c8d0648e3eb076823d0c8835dc422dac0c67d Mon Sep 17 00:00:00 2001 From: MoumitaM Date: Wed, 27 Mar 2024 11:37:23 +0530 Subject: [PATCH] chore: modify configuration for getAsyncData fn --- .../components/userSessionManager/UserSessionManager.test.ts | 2 ++ .../src/components/userSessionManager/UserSessionManager.ts | 1 + 2 files changed, 3 insertions(+) diff --git a/packages/analytics-js/__tests__/components/userSessionManager/UserSessionManager.test.ts b/packages/analytics-js/__tests__/components/userSessionManager/UserSessionManager.test.ts index 3c914ae2c..2533d27b4 100644 --- a/packages/analytics-js/__tests__/components/userSessionManager/UserSessionManager.test.ts +++ b/packages/analytics-js/__tests__/components/userSessionManager/UserSessionManager.test.ts @@ -1435,6 +1435,7 @@ describe('User session manager', () => { }), sendRawData: true, }, + isRawResponse: true, callback: expect.any(Function), }); }); @@ -1465,6 +1466,7 @@ describe('User session manager', () => { }), sendRawData: true, }, + isRawResponse: true, callback: expect.any(Function), }); }); diff --git a/packages/analytics-js/src/components/userSessionManager/UserSessionManager.ts b/packages/analytics-js/src/components/userSessionManager/UserSessionManager.ts index 4ca884cbd..de959ca22 100644 --- a/packages/analytics-js/src/components/userSessionManager/UserSessionManager.ts +++ b/packages/analytics-js/src/components/userSessionManager/UserSessionManager.ts @@ -298,6 +298,7 @@ class UserSessionManager implements IUserSessionManager { }) as string, sendRawData: true, }, + isRawResponse: true, callback: (res, details) => { if (details?.xhr?.status === 200) { const cookieValue = store?.get(key);