From 7c12e4fb8fdd6b500750253beda31771a5aa49fc Mon Sep 17 00:00:00 2001 From: David Vacca Date: Mon, 5 Feb 2024 18:05:24 -0800 Subject: [PATCH] Mark classes of package uimanager/util as @Nullsafe (#42861) Summary: Pull Request resolved: https://github.com/facebook/react-native/pull/42861 All these classes are NullSafe, let's mark them as NullSafe(Local) to ensure lint detect errors in the future changelog: [internal] internal Reviewed By: rshest Differential Revision: D53393474 fbshipit-source-id: 4bbdf72729d3a84ad90a3071d8abcedefbe89878 --- .../com/facebook/react/uimanager/util/ReactFindViewUtil.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/packages/react-native/ReactAndroid/src/main/java/com/facebook/react/uimanager/util/ReactFindViewUtil.java b/packages/react-native/ReactAndroid/src/main/java/com/facebook/react/uimanager/util/ReactFindViewUtil.java index 3b5d448815f..ccfd1fa655a 100644 --- a/packages/react-native/ReactAndroid/src/main/java/com/facebook/react/uimanager/util/ReactFindViewUtil.java +++ b/packages/react-native/ReactAndroid/src/main/java/com/facebook/react/uimanager/util/ReactFindViewUtil.java @@ -10,6 +10,7 @@ package com.facebook.react.uimanager.util; import android.view.View; import android.view.ViewGroup; import androidx.annotation.Nullable; +import com.facebook.infer.annotation.Nullsafe; import com.facebook.react.R; import java.util.ArrayList; import java.util.HashMap; @@ -19,6 +20,7 @@ import java.util.Map; import java.util.Set; /** Finds views in React Native view hierarchies */ +@Nullsafe(Nullsafe.Mode.LOCAL) public class ReactFindViewUtil { private static final List mOnViewFoundListeners = new ArrayList<>();