Skip to content

Commit

Permalink
[apacheGH-652] add check for openInSystem postNotification
Browse files Browse the repository at this point in the history
  • Loading branch information
Jim Wright committed Mar 24, 2020
1 parent e78ffe7 commit 97677a6
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/ios/CDVWKInAppBrowser.m
Original file line number Diff line number Diff line change
Expand Up @@ -357,8 +357,10 @@ - (void)openInCordovaWebView:(NSURL*)url withOptions:(NSString*)options

- (void)openInSystem:(NSURL*)url
{
[[NSNotificationCenter defaultCenter] postNotification:[NSNotification notificationWithName:CDVPluginHandleOpenURLNotification object:url]];
[[UIApplication sharedApplication] openURL:url];
if ([[UIApplication sharedApplication] openURL:url] == NO) {
[[NSNotificationCenter defaultCenter] postNotification:[NSNotification notificationWithName:CDVPluginHandleOpenURLNotification object:url]];
[[UIApplication sharedApplication] openURL:url];
}
}

- (void)loadAfterBeforeload:(CDVInvokedUrlCommand*)command
Expand Down

0 comments on commit 97677a6

Please sign in to comment.