1- import { addBreadcrumb } from '@sentry/core' ;
21import type { Event , EventHint } from '@sentry/types' ;
32import { logger } from '@sentry/utils' ;
43
@@ -50,13 +49,6 @@ export function handleGlobalEventListener(
5049 event . tags = { ...event . tags , replayId : replay . getSessionId ( ) } ;
5150 }
5251
53- if ( __DEBUG_BUILD__ && replay . getOptions ( ) . _experiments . traceInternals && isErrorEvent ( event ) ) {
54- const exc = getEventExceptionValues ( event ) ;
55- addInternalBreadcrumb ( {
56- message : `Tagging event (${ event . event_id } ) - ${ event . message } - ${ exc . type } : ${ exc . value } ` ,
57- } ) ;
58- }
59-
6052 // In cases where a custom client is used that does not support the new hooks (yet),
6153 // we manually call this hook method here
6254 if ( afterSendHandler ) {
@@ -67,22 +59,3 @@ export function handleGlobalEventListener(
6759 return event ;
6860 } ;
6961}
70-
71- function addInternalBreadcrumb ( arg : Parameters < typeof addBreadcrumb > [ 0 ] ) : void {
72- const { category, level, message, ...rest } = arg ;
73-
74- addBreadcrumb ( {
75- category : category || 'console' ,
76- level : level || 'debug' ,
77- message : `[debug]: ${ message } ` ,
78- ...rest ,
79- } ) ;
80- }
81-
82- function getEventExceptionValues ( event : Event ) : { type : string ; value : string } {
83- return {
84- type : 'Unknown' ,
85- value : 'n/a' ,
86- ...( event . exception && event . exception . values && event . exception . values [ 0 ] ) ,
87- } ;
88- }
0 commit comments