From 23b6240b256b2afb0e5efb2cef1ce27cbd0fcdf8 Mon Sep 17 00:00:00 2001 From: Paige Sun Date: Mon, 18 Apr 2022 18:57:40 -0700 Subject: [PATCH] (Easy) Add RCTNotAllowedInAppWideFabric validation to the only static method in RCTUIManager, JSResponder Summary: Changelog: [Internal][iOS] Add validation log to the only static method in RCTUIManager, JSResponder When all surfaces of an app has been fully migrated to Fabric, we don't expect `[RCTUIManager JSResponder]` to be called, so I'm expecting this API to be broken on Fabric and Bridgeless. Reviewed By: RSNara Differential Revision: D35723794 fbshipit-source-id: ec786946a33fca98c89e8cad0e0467bf45dc1735 --- React/Modules/RCTUIManager.m | 2 ++ 1 file changed, 2 insertions(+) diff --git a/React/Modules/RCTUIManager.m b/React/Modules/RCTUIManager.m index 9124494b5fd..486bc9845b1 100644 --- a/React/Modules/RCTUIManager.m +++ b/React/Modules/RCTUIManager.m @@ -1656,6 +1656,8 @@ static UIView *_jsResponder; + (UIView *)JSResponder { + RCTErrorNewArchitectureValidation( + RCTNotAllowedInAppWideFabric, @"RCTUIManager", @"Please migrate this legacy surface to Fabric."); return _jsResponder; }