Skip to content

Commit 0bb5cfb

Browse files
committed
feat(v8/core): Remove deprecated client.setupIntegrations method
1 parent 4ba3e40 commit 0bb5cfb

File tree

3 files changed

+2
-27
lines changed

3 files changed

+2
-27
lines changed

packages/core/src/baseclient.ts

Lines changed: 0 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -100,9 +100,6 @@ export abstract class BaseClient<O extends ClientOptions> implements Client<O> {
100100
/** Array of set up integrations. */
101101
protected _integrations: IntegrationIndex;
102102

103-
/** Indicates whether this client's integrations have been set up. */
104-
protected _integrationsInitialized: boolean;
105-
106103
/** Number of calls being processed */
107104
protected _numProcessing: number;
108105

@@ -122,7 +119,6 @@ export abstract class BaseClient<O extends ClientOptions> implements Client<O> {
122119
protected constructor(options: O) {
123120
this._options = options;
124121
this._integrations = {};
125-
this._integrationsInitialized = false;
126122
this._numProcessing = 0;
127123
this._outcomes = {};
128124
this._hooks = {};
@@ -303,16 +299,6 @@ export abstract class BaseClient<O extends ClientOptions> implements Client<O> {
303299
this._eventProcessors.push(eventProcessor);
304300
}
305301

306-
/**
307-
* This is an internal function to setup all integrations that should run on the client.
308-
* @deprecated Use `client.init()` instead.
309-
*/
310-
public setupIntegrations(forceInitialize?: boolean): void {
311-
if ((forceInitialize && !this._integrationsInitialized) || (this._isEnabled() && !this._integrationsInitialized)) {
312-
this._setupIntegrations();
313-
}
314-
}
315-
316302
/** @inheritdoc */
317303
public init(): void {
318304
if (this._isEnabled()) {
@@ -533,9 +519,6 @@ export abstract class BaseClient<O extends ClientOptions> implements Client<O> {
533519
const { integrations } = this._options;
534520
this._integrations = setupIntegrations(this, integrations);
535521
afterSetupIntegrations(this, integrations);
536-
537-
// TODO v8: We don't need this flag anymore
538-
this._integrationsInitialized = true;
539522
}
540523

541524
/** Updates existing session based on the provided event */

packages/core/src/hub.ts

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -165,10 +165,8 @@ export class Hub implements HubInterface {
165165
const top = this.getStackTop();
166166
top.client = client;
167167
top.scope.setClient(client);
168-
// eslint-disable-next-line deprecation/deprecation
169-
if (client && client.setupIntegrations) {
170-
// eslint-disable-next-line deprecation/deprecation
171-
client.setupIntegrations();
168+
if (client) {
169+
client.init();
172170
}
173171
}
174172

packages/types/src/client.ts

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -139,12 +139,6 @@ export interface Client<O extends ClientOptions = ClientOptions> {
139139
* */
140140
addIntegration(integration: Integration): void;
141141

142-
/**
143-
* This is an internal function to setup all integrations that should run on the client.
144-
* @deprecated Use `client.init()` instead.
145-
*/
146-
setupIntegrations(forceInitialize?: boolean): void;
147-
148142
/**
149143
* Initialize this client.
150144
* Call this after the client was set on a scope.

0 commit comments

Comments
 (0)