Skip to content

Commit 2271282

Browse files
mydeachargome
authored andcommitted
small ref
1 parent ce13e76 commit 2271282

File tree

1 file changed

+4
-6
lines changed

1 file changed

+4
-6
lines changed

packages/node/src/integrations/http/SentryHttpInstrumentation.ts

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -268,12 +268,10 @@ export class SentryHttpInstrumentation extends InstrumentationBase<SentryHttpIns
268268
? getMergedHeadersForRequestOptions(url, optionsParsed, instrumentation._propagationDecisionMap)
269269
: undefined;
270270

271-
// If we are not proapgating traces, we skip touching the args for the request at all
272-
const request = mergedHeaders
273-
? (original.apply(this, getOutgoingRequestArgsWithHeaders(argsCopy, mergedHeaders)) as ReturnType<
274-
typeof http.request
275-
>)
276-
: (original.apply(this, args) as ReturnType<typeof http.request>);
271+
// If we are not proapgating traces, we skip touching the args for the request at all
272+
const request: ReturnType<typeof http.request> = mergedHeaders
273+
? original.apply(this, getOutgoingRequestArgsWithHeaders(argsCopy, mergedHeaders))
274+
: original.apply(this, args);
277275

278276
request.prependListener('response', (response: http.IncomingMessage) => {
279277
const _breadcrumbs = instrumentation.getConfig().breadcrumbs;

0 commit comments

Comments
 (0)