Skip to content

Commit a561697

Browse files
committed
Patch up rebase
1 parent dc9988c commit a561697

File tree

5 files changed

+8
-29
lines changed

5 files changed

+8
-29
lines changed

packages/nextjs/src/config/templates/proxyLoaderTemplate.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ const origGetStaticProps = userPageModule.getStaticProps;
2727
const origGetServerSideProps = userPageModule.getServerSideProps;
2828

2929
if (typeof origGetInitialProps === 'function') {
30-
pageComponent.getInitialProps = Sentry.withSentryGetInitialProps(
30+
pageComponent.getInitialProps = Sentry.withSentryServerSideGetInitialProps(
3131
origGetInitialProps,
3232
'__ROUTE__',
3333
) as NextPageComponent['getInitialProps'];
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
export { withSentryGetStaticProps } from './withSentryGetStaticProps';
2-
export { withSentryGetInitialProps } from './withSentryGetInitialProps';
32
export { withSentryGetServerSideProps } from './withSentryGetServerSideProps';
3+
export { withSentryServerSideGetInitialProps } from './withSentryServerSideGetInitialProps';

packages/nextjs/src/config/wrappers/withSentryGetInitialProps.ts

-26
This file was deleted.

packages/nextjs/src/config/wrappers/withSentryGetServerSideProps.ts

+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
import { hasTracingEnabled } from '@sentry/tracing';
12
import { GetServerSideProps } from 'next';
23

34
import { isBuild } from '../../utils/isBuild';

packages/nextjs/src/index.server.ts

+5-1
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,11 @@ function addServerIntegrations(options: NextjsOptions): void {
125125
export type { SentryWebpackPluginOptions } from './config/types';
126126
export { withSentryConfig } from './config';
127127
export { isBuild } from './utils/isBuild';
128-
export { withSentryGetServerSideProps, withSentryGetStaticProps, withSentryGetInitialProps } from './config/wrappers';
128+
export {
129+
withSentryGetServerSideProps,
130+
withSentryGetStaticProps,
131+
withSentryServerSideGetInitialProps,
132+
} from './config/wrappers';
129133
export { withSentry } from './utils/withSentry';
130134

131135
// Wrap various server methods to enable error monitoring and tracing. (Note: This only happens for non-Vercel

0 commit comments

Comments
 (0)