Skip to content

Commit b065040

Browse files
committed
only capture for events
1 parent a733a15 commit b065040

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

packages/browser/src/integrations/view-hierarchy.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,8 @@ export const viewHierarchyIntegration = defineIntegration((options: Options = {}
115115
return {
116116
name: 'ViewHierarchy',
117117
processEvent: (event, hint) => {
118-
if (options.shouldAttach?.(event, hint) === false) {
118+
// only capture for error events
119+
if (event.type !== undefined || options.shouldAttach?.(event, hint) === false) {
119120
return event;
120121
}
121122

0 commit comments

Comments
 (0)