@@ -3,7 +3,7 @@ import { Integration, Severity } from '@sentry/types';
3
3
import { isFunction , isString } from '@sentry/utils/is' ;
4
4
import { getEventDescription , getGlobalObject , parseUrl } from '@sentry/utils/misc' ;
5
5
import { deserialize , fill } from '@sentry/utils/object' ;
6
- import { safeJoin } from '@sentry/utils/string' ;
6
+ import { includes , safeJoin } from '@sentry/utils/string' ;
7
7
import { supportsBeacon , supportsHistory , supportsNativeFetch } from '@sentry/utils/supports' ;
8
8
import { BrowserOptions } from '../backend' ;
9
9
import { breadcrumbEventHandler , keypressEventHandler , wrap } from './helpers' ;
@@ -97,7 +97,7 @@ export class Breadcrumbs implements Integration {
97
97
98
98
// if Sentry key appears in URL, don't capture it as a request
99
99
// but rather as our own 'sentry' type breadcrumb
100
- if ( options . filterUrl && url . includes ( options . filterUrl ) ) {
100
+ if ( options . filterUrl && includes ( url , options . filterUrl ) ) {
101
101
addSentryBreadcrumb ( data ) ;
102
102
return result ;
103
103
}
@@ -210,7 +210,7 @@ export class Breadcrumbs implements Integration {
210
210
211
211
// if Sentry key appears in URL, don't capture it as a request
212
212
// but rather as our own 'sentry' type breadcrumb
213
- if ( options . filterUrl && url . includes ( options . filterUrl ) ) {
213
+ if ( options . filterUrl && includes ( url , options . filterUrl ) ) {
214
214
if ( method === 'POST' && args [ 1 ] && args [ 1 ] . body ) {
215
215
addSentryBreadcrumb ( args [ 1 ] . body ) ;
216
216
}
@@ -371,7 +371,7 @@ export class Breadcrumbs implements Integration {
371
371
} ;
372
372
// if Sentry key appears in URL, don't capture it as a request
373
373
// but rather as our own 'sentry' type breadcrumb
374
- if ( isString ( url ) && ( options . filterUrl && url . includes ( options . filterUrl ) ) ) {
374
+ if ( isString ( url ) && ( options . filterUrl && includes ( url , options . filterUrl ) ) ) {
375
375
this . __sentry_own_request__ = true ;
376
376
}
377
377
return originalOpen . apply ( this , args ) ;
0 commit comments