Skip to content

Commit

Permalink
💫 Update: RNIModalView.insertReactSubview
Browse files Browse the repository at this point in the history
  • Loading branch information
dominicstop committed Apr 21, 2023
1 parent f60b2ed commit 1807146
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions ios/src_library/React Native/RNIModalView/RNIModalView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -404,8 +404,11 @@ public class RNIModalView:

switch nativeIDKey {
case .modalViewContent:
if let oldModalContentWrapper = self.modalContentWrapper,
wrapperView !== oldModalContentWrapper {
guard self.modalContentWrapper !== wrapperView,
self.modalContentWrapper?.reactTag != wrapperView.reactTag
else { return };

if let oldModalContentWrapper = self.modalContentWrapper {

oldModalContentWrapper.cleanup();
self.modalContentWrapper = nil;
Expand Down

0 comments on commit 1807146

Please sign in to comment.