From fff555278d2a07e51c58ef30881a1ac6ab54d2e1 Mon Sep 17 00:00:00 2001 From: Kacper Kafara Date: Tue, 10 Dec 2024 21:46:35 +0100 Subject: [PATCH] Actual fix --- ios/RNSScreenStack.mm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ios/RNSScreenStack.mm b/ios/RNSScreenStack.mm index c8896735e..bfeeb002c 100644 --- a/ios/RNSScreenStack.mm +++ b/ios/RNSScreenStack.mm @@ -1281,7 +1281,7 @@ - (void)invalidate // with modal presentation or foreign modal presented from inside a Screen. - (void)dismissAllRelatedModals { - // [_controller dismissViewControllerAnimated:YES completion:nil]; + [_controller.presentedViewController dismissViewControllerAnimated:YES completion:nil]; // This loop seems to be excessive. Above message send to `_controller` should // be enough, because system dismisses the controllers recursively,