Skip to content

Commit 79838ff

Browse files
committed
Fixes #156 - Add nil check for address
1 parent f6e1c30 commit 79838ff

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

ios/RNSentry.m

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,11 @@ - (NSInteger)indexOfReactNativeCallFrame:(NSArray<SentryFrame *> *)frames native
132132
}
133133

134134
- (void)injectReactNativeFrames:(SentryEvent *)event {
135-
NSString *address = event.extra[@"__sentry_address"];
135+
NSString *address = [event.extra valueForKey:@"__sentry_address"];
136+
if (nil == address) {
137+
// We bail out here since __sentry_address is not set
138+
return;
139+
}
136140
SentryThread *crashedThread = nil;
137141
for (SentryThread *thread in event.threads) {
138142
if ([thread.crashed boolValue]) {

0 commit comments

Comments
 (0)