From 047f645079544ff76124b7d0fe5059e4cde14c06 Mon Sep 17 00:00:00 2001 From: Alex Hunt Date: Tue, 3 Oct 2023 14:35:40 -0400 Subject: [PATCH] Fix typings for ReactNativeVersionCheck MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Applies correct fix for `_formatVersion` misalignment — based on #36657. --- .../react-native/Libraries/Core/ReactNativeVersionCheck.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/packages/react-native/Libraries/Core/ReactNativeVersionCheck.js b/packages/react-native/Libraries/Core/ReactNativeVersionCheck.js index 8b41988696d..a9e1bc4b1f6 100644 --- a/packages/react-native/Libraries/Core/ReactNativeVersionCheck.js +++ b/packages/react-native/Libraries/Core/ReactNativeVersionCheck.js @@ -40,7 +40,9 @@ exports.checkVersions = function checkVersions(): void { }; function _formatVersion( - version: (typeof Platform)['constants']['reactNativeVersion'], + version: + | (typeof Platform)['constants']['reactNativeVersion'] + | {major: number, minor: number, patch: number, prerelease: ?string}, ): string { return ( `${version.major}.${version.minor}.${version.patch}` +