We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e5210d3 commit 06bccc6Copy full SHA for 06bccc6
packages/core/src/utils/spanUtils.ts
@@ -332,15 +332,12 @@ export function getStatusMessage(status: SpanStatus | undefined): string | undef
332
* Convert the various statuses to the simple onces expected by Sentry for steamed spans ('ok' is default).
333
*/
334
export function getSimpleStatusMessage(status: SpanStatus | undefined): 'ok' | 'error' {
335
- if (
336
- !status ||
+ return !status ||
337
status.code === SPAN_STATUS_OK ||
338
status.code === SPAN_STATUS_UNSET ||
339
status.message === 'cancelled'
340
- ) {
341
- return 'ok';
342
- }
343
- return 'error';
+ ? 'ok'
+ : 'error';
344
}
345
346
const CHILD_SPANS_FIELD = '_sentryChildSpans';
0 commit comments