diff --git a/packages/react-native/scripts/cocoapods/privacy_manifest_utils.rb b/packages/react-native/scripts/cocoapods/privacy_manifest_utils.rb index 691aed5bd2a75c..220d5d55eece46 100644 --- a/packages/react-native/scripts/cocoapods/privacy_manifest_utils.rb +++ b/packages/react-native/scripts/cocoapods/privacy_manifest_utils.rb @@ -105,7 +105,7 @@ def self.get_used_required_reason_apis(installer) if File.basename(file_path) == 'PrivacyInfo.xcprivacy' content = Xcodeproj::Plist.read_from_path(file_path) accessed_api_types = content["NSPrivacyAccessedAPITypes"] - accessed_api_types.each do |accessed_api| + accessed_api_types&.each do |accessed_api| api_type = accessed_api["NSPrivacyAccessedAPIType"] reasons = accessed_api["NSPrivacyAccessedAPITypeReasons"] next unless api_type