Skip to content

Commit dbea48f

Browse files
author
Russell Martin
committed
Avoid stringifying null redirect url
1 parent 997de9f commit dbea48f

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

ios/RNInAppBrowser.m

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,10 @@ + (BOOL)requiresMainQueueSetup
9090
}
9191
};
9292

93-
NSString *escapedRedirectURL = [[NSURL alloc] initWithString:redirectURL].scheme;
93+
NSString *escapedRedirectURL = nil;
94+
if (redirectURL) {
95+
escapedRedirectURL = [[NSURL alloc] initWithString:redirectURL].scheme;
96+
}
9497

9598
if (@available(iOS 12.0, *)) {
9699
webAuthSession = [[ASWebAuthenticationSession alloc]

0 commit comments

Comments
 (0)