Skip to content

Commit 2ff6337

Browse files
author
Luca Forstner
committed
Fix tests
1 parent 37691cd commit 2ff6337

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

packages/core/src/baseclient.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -518,7 +518,9 @@ export abstract class BaseClient<O extends ClientOptions> implements Client<O> {
518518
if (event.spans) {
519519
normalized.spans = event.spans.map(span => {
520520
// We cannot use the spread operator on span here because that overwrites the `toJSON` method
521-
span.data = normalize(span.data, depth, maxBreadth);
521+
if (span.data) {
522+
span.data = normalize(span.data, depth, maxBreadth);
523+
}
522524
return span;
523525
});
524526
}

0 commit comments

Comments
 (0)