Skip to content

Commit 805ba1b

Browse files
committed
avoid empty query
1 parent 6e2b6eb commit 805ba1b

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

packages/node/src/integrations/node-fetch/undici-instrumentation.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -200,7 +200,7 @@ function onRequestCreated(config: UndiciInstrumentationConfig, { request }: Requ
200200
[ATTR_HTTP_REQUEST_METHOD_ORIGINAL]: request.method,
201201
[URL_FULL]: requestUrl.toString(),
202202
[URL_PATH]: requestUrl.pathname,
203-
[URL_QUERY]: requestUrl.search,
203+
[URL_QUERY]: requestUrl.search || undefined,
204204
[URL_SCHEME]: urlScheme,
205205
[SEMANTIC_ATTRIBUTE_SENTRY_ORIGIN]: 'auto.http.otel.node_fetch',
206206
};

0 commit comments

Comments
 (0)