Skip to content

Commit a3e44f2

Browse files
move helpers to core
1 parent ce56427 commit a3e44f2

File tree

4 files changed

+9
-4
lines changed

4 files changed

+9
-4
lines changed

packages/browser/src/client.ts

+7-2
Original file line numberDiff line numberDiff line change
@@ -9,11 +9,16 @@ import type {
99
Scope,
1010
SeverityLevel,
1111
} from '@sentry/core';
12-
import { Client, applySdkMetadata, getSDKSource } from '@sentry/core';
12+
import {
13+
Client,
14+
addAutoIpAddressToSession,
15+
addAutoIpAddressToUser,
16+
applySdkMetadata,
17+
getSDKSource,
18+
} from '@sentry/core';
1319
import { eventFromException, eventFromMessage } from './eventbuilder';
1420
import { WINDOW } from './helpers';
1521
import type { BrowserTransportOptions } from './transports/types';
16-
import { addAutoIpAddressToSession, addAutoIpAddressToUser } from './utils/ipAddress';
1722

1823
/**
1924
* Configuration options for the Sentry Browser SDK.

packages/browser/src/exports.ts

-1
Original file line numberDiff line numberDiff line change
@@ -99,4 +99,3 @@ export { linkedErrorsIntegration } from './integrations/linkederrors';
9999
export { browserApiErrorsIntegration } from './integrations/browserapierrors';
100100

101101
export { lazyLoadIntegration } from './utils/lazyLoadIntegration';
102-
export { addAutoIpAddressToSession, addAutoIpAddressToUser } from './utils/ipAddress';

packages/core/src/index.ts

+1
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,7 @@ export { hasTracingEnabled } from './utils/hasTracingEnabled';
7272
export { isSentryRequestUrl } from './utils/isSentryRequestUrl';
7373
export { handleCallbackErrors } from './utils/handleCallbackErrors';
7474
export { parameterize } from './utils/parameterize';
75+
export { addAutoIpAddressToSession, addAutoIpAddressToUser } from './utils/ipAddress';
7576
export {
7677
spanToTraceHeader,
7778
spanToJSON,

packages/browser/src/utils/ipAddress.ts renamed to packages/core/src/utils/ipAddress.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import type { Session, SessionAggregates, User } from '@sentry/core';
1+
import type { Session, SessionAggregates, User } from '../types-hoist';
22

33
// By default, we want to infer the IP address, unless this is explicitly set to `null`
44
// We do this after all other processing is done

0 commit comments

Comments
 (0)