Skip to content

Commit

Permalink
Fix crash in SFSafariViewController
Browse files Browse the repository at this point in the history
  • Loading branch information
weibel committed May 27, 2024
1 parent bd7317c commit b3ea3c6
Showing 1 changed file with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,11 @@ - (BOOL)openURL:(NSURL *)url onClickthroughExitBlock:(nullable PBMVoidBlock)onCl
return NO;
}

if (!([strURLscheme isEqualToString:@"http"] || [strURLscheme isEqualToString:@"https"])) {
PBMLogError(@"Attempting to open url [%@] in SFSafariViewController. SFSafariViewController only supports initial URLs with http:// or https:// schemes.", url);
return NO;
}

//Show clickthrough browser

return [self openClickthroughWithURL:url
Expand Down

0 comments on commit b3ea3c6

Please sign in to comment.