File tree Expand file tree Collapse file tree 1 file changed +11
-1
lines changed
ReactAndroid/src/main/java/com/facebook/react/uimanager Expand file tree Collapse file tree 1 file changed +11
-1
lines changed Original file line number Diff line number Diff line change @@ -93,7 +93,13 @@ private static UIManager getUIManager(
93
93
*/
94
94
@ Nullable
95
95
public static EventDispatcher getEventDispatcherForReactTag (ReactContext context , int reactTag ) {
96
- return getEventDispatcher (context , getUIManagerType (reactTag ));
96
+ EventDispatcher eventDispatcher = getEventDispatcher (context , getUIManagerType (reactTag ));
97
+ if (eventDispatcher == null ) {
98
+ ReactSoftException .logSoftException (
99
+ "UIManagerHelper" ,
100
+ new IllegalStateException ("Cannot get EventDispatcher for reactTag " + reactTag ));
101
+ }
102
+ return eventDispatcher ;
97
103
}
98
104
99
105
/**
@@ -112,6 +118,10 @@ public static EventDispatcher getEventDispatcher(
112
118
}
113
119
UIManager uiManager = getUIManager (context , uiManagerType , false );
114
120
if (uiManager == null ) {
121
+ ReactSoftException .logSoftException (
122
+ "UIManagerHelper" ,
123
+ new ReactNoCrashSoftException (
124
+ "Unable to find UIManager for UIManagerType " + uiManagerType ));
115
125
return null ;
116
126
}
117
127
EventDispatcher eventDispatcher = (EventDispatcher ) uiManager .getEventDispatcher ();
You can’t perform that action at this time.
0 commit comments