Skip to content

Commit c1d7581

Browse files
committed
add request to scope metadata in withSentry
1 parent 951065e commit c1d7581

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

packages/nextjs/src/utils/withSentry.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,7 @@ export const withSentry = (origHandler: NextApiHandler): WrappedNextApiHandler =
5959
currentScope.addEventProcessor(event =>
6060
event.type !== 'transaction' ? addRequestDataToEvent(event, req) : event,
6161
);
62+
currentScope.setSDKProcessingMetadata({ request: req });
6263

6364
if (hasTracingEnabled()) {
6465
// If there is a trace header set, extract the data from it (parentSpanId, traceId, and sampling decision)

0 commit comments

Comments
 (0)