diff --git a/CHANGELOG.md b/CHANGELOG.md index 61ca5d02cb..2e286bd56c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,6 +8,10 @@ ## Unreleased +### Major Changes + +- `Sentry.captureUserFeedback` removed, use `Sentry.captureFeedback` instead ([#4855](https://github.com/getsentry/sentry-react-native/pull/4855)) + ### Changes - Use `Replay` interface for `browserReplayIntegration` return type ([#4858](https://github.com/getsentry/sentry-react-native/pull/4858)) diff --git a/packages/core/src/js/index.ts b/packages/core/src/js/index.ts index fb931312d9..f5de2fd307 100644 --- a/packages/core/src/js/index.ts +++ b/packages/core/src/js/index.ts @@ -60,7 +60,7 @@ export { SDK_NAME, SDK_VERSION } from './version'; export type { ReactNativeOptions } from './options'; export { ReactNativeClient } from './client'; -export { init, wrap, nativeCrash, flush, close, captureUserFeedback, withScope, crashedLastRun } from './sdk'; +export { init, wrap, nativeCrash, flush, close, withScope, crashedLastRun } from './sdk'; export { TouchEventBoundary, withTouchEventBoundary } from './touchevents'; export { diff --git a/packages/core/src/js/sdk.tsx b/packages/core/src/js/sdk.tsx index 657ec2db59..b0f2ad5704 100644 --- a/packages/core/src/js/sdk.tsx +++ b/packages/core/src/js/sdk.tsx @@ -1,6 +1,16 @@ /* eslint-disable complexity */ -import type { Breadcrumb, BreadcrumbHint, Integration, Scope, SendFeedbackParams, UserFeedback } from '@sentry/core'; -import { captureFeedback, getClient, getGlobalScope, getIntegrationsToSetup, getIsolationScope, initAndBind, logger, makeDsn, stackParserFromStackParserOptions, withScope as coreWithScope } from '@sentry/core'; +import type { Breadcrumb, BreadcrumbHint, Integration, Scope } from '@sentry/core'; +import { + getClient, + getGlobalScope, + getIntegrationsToSetup, + getIsolationScope, + initAndBind, + logger, + makeDsn, + stackParserFromStackParserOptions, + withScope as coreWithScope, +} from '@sentry/core'; import { defaultStackParser, makeFetchTransport, @@ -219,20 +229,6 @@ export async function close(): Promise { } } -/** - * Captures user feedback and sends it to Sentry. - * @deprecated Use `Sentry.captureFeedback` instead. - */ -export function captureUserFeedback(feedback: UserFeedback): void { - const feedbackParams: SendFeedbackParams = { - name: feedback.name, - email: feedback.email, - message: feedback.comments, - associatedEventId: feedback.event_id, - }; - captureFeedback(feedbackParams); -} - /** * Creates a new scope with and executes the given operation within. * The scope is automatically removed once the operation