Skip to content

Commit 48889d8

Browse files
authored
Merge pull request #40 from brentvatne/@brent/expo-compat
Add setDataCallback
2 parents 786b39b + 8ab5522 commit 48889d8

File tree

1 file changed

+13
-1
lines changed

1 file changed

+13
-1
lines changed

lib/Sentry.js

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import {
22
NativeModules
33
} from 'react-native';
4-
import Raven from 'raven-js';;
4+
import Raven from 'raven-js';
55

66
const {
77
RNSentry
@@ -73,6 +73,10 @@ export class Sentry {
7373
Sentry._dsn = dsn;
7474
Sentry.options = {
7575
logLevel: SentryLog.None,
76+
instrument: {
77+
timers: false,
78+
eventTargets: false,
79+
}
7680
}
7781
Object.assign(Sentry.options, options);
7882
return Sentry;
@@ -90,6 +94,10 @@ export class Sentry {
9094
if (Sentry.isNativeClientAvailable()) Sentry._nativeClient.nativeCrash();
9195
}
9296

97+
static setDataCallback(callback) {
98+
Sentry._ravenClient.setDataCallback(callback);
99+
}
100+
93101
static setUserContext(user) {
94102
Sentry._ravenClient.setUserContext(user);
95103
if (Sentry.isNativeClientAvailable()) Sentry._nativeClient.setUserContext(user);
@@ -263,6 +271,10 @@ class RavenClient {
263271
}
264272
}
265273

274+
setDataCallback(callback) {
275+
Raven.setDataCallback(callback);
276+
}
277+
266278
setUserContext(user) {
267279
Raven.setUserContext(user);
268280
}

0 commit comments

Comments
 (0)