File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -128,7 +128,8 @@ - (dispatch_queue_t)methodQueue
128128 // This is a hack to present the SafariViewController modally
129129 UINavigationController *safariHackVC = [[UINavigationController alloc ] initWithRootViewController: safariVC];
130130 [safariHackVC setNavigationBarHidden: true animated: false ];
131- [RCTPresentedViewController () presentViewController: safariHackVC animated: true completion: nil ];
131+ UIViewController *presentingViewController = RCTPresentedViewController ();
132+ [presentingViewController presentViewController: safariHackVC animated: true completion: nil ];
132133}
133134
134135- (void )performSynchronouslyOnMainThread : (void (^)(void ))block
@@ -144,7 +145,8 @@ - (void)_close
144145{
145146 __weak typeof (self) weakSelf = self;
146147 [self performSynchronouslyOnMainThread: ^{
147- [RCTPresentedViewController () dismissViewControllerAnimated: YES completion: ^{
148+ UIViewController *presentingViewController = RCTPresentedViewController ();
149+ [presentingViewController dismissViewControllerAnimated: YES completion: ^{
148150 __strong typeof (self) strongSelf = weakSelf;
149151 if (strongSelf) {
150152 strongSelf.redirectResolve (@{
You can’t perform that action at this time.
0 commit comments