Skip to content

Commit d834197

Browse files
zhongwuzwfacebook-github-bot
authored andcommitted
Fix build error warning of Text module (#23586)
Summary: Throw error warning when build Text module, we can add tvOS available check to remove error. [iOS] [Fixed] - Fix build error warning of Text module Pull Request resolved: #23586 Differential Revision: D14181198 Pulled By: cpojer fbshipit-source-id: 6a62c831ba119ddcbc6effa0b24f22bd4588b982
1 parent 4a80776 commit d834197

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Libraries/Text/TextInput/RCTBaseTextInputView.m

+2-2
Original file line numberDiff line numberDiff line change
@@ -235,7 +235,7 @@ - (void)setTextContentType:(NSString *)type
235235
};
236236

237237
#if __IPHONE_OS_VERSION_MAX_ALLOWED >= 110000 /* __IPHONE_11_0 */
238-
if (@available(iOS 11.0, *)) {
238+
if (@available(iOS 11.0, tvOS 11.0, *)) {
239239
NSDictionary<NSString *, NSString *> * iOS11extras = @{@"username": UITextContentTypeUsername,
240240
@"password": UITextContentTypePassword};
241241

@@ -247,7 +247,7 @@ - (void)setTextContentType:(NSString *)type
247247
#endif
248248

249249
#if __IPHONE_OS_VERSION_MAX_ALLOWED >= 120000 /* __IPHONE_12_0 */
250-
if (@available(iOS 12.0, *)) {
250+
if (@available(iOS 12.0, tvOS 12.0, *)) {
251251
NSDictionary<NSString *, NSString *> * iOS12extras = @{@"newPassword": UITextContentTypeNewPassword,
252252
@"oneTimeCode": UITextContentTypeOneTimeCode};
253253

0 commit comments

Comments
 (0)