diff --git a/React/Base/RCTConvert.h b/React/Base/RCTConvert.h index 7a7cc75ebdc..386c17175d3 100644 --- a/React/Base/RCTConvert.h +++ b/React/Base/RCTConvert.h @@ -173,7 +173,7 @@ RCT_EXTERN NSArray *RCTConvertArrayValue(SEL, id); * avoid repeating the same boilerplate for every error message. */ #define RCTLogConvertError(json, typeName) \ - RCTLogError(@"JSON value '%@' of type %@ cannot be converted to %@", json, [json classForCoder], typeName) + RCTLogInfo(@"JSON value '%@' of type %@ cannot be converted to %@", json, [json classForCoder], typeName) /** * This macro is used for creating simple converter functions that just call diff --git a/React/Base/RCTConvert.m b/React/Base/RCTConvert.m index 5e4820585b0..a2dfa2bcf6d 100644 --- a/React/Base/RCTConvert.m +++ b/React/Base/RCTConvert.m @@ -69,7 +69,7 @@ RCT_CUSTOM_CONVERTER(NSData *, NSData, [json dataUsingEncoding:NSUTF8StringEncod for (NSNumber *number in json) { NSInteger index = number.integerValue; if (RCT_DEBUG && index < 0) { - RCTLogError(@"Invalid index value %lld. Indices must be positive.", (long long)index); + RCTLogInfo(@"Invalid index value %lld. Indices must be positive.", (long long)index); } [indexSet addIndex:index]; } @@ -169,7 +169,7 @@ RCT_ENUM_CONVERTER( __block BOOL allHeadersAreStrings = YES; [headers enumerateKeysAndObjectsUsingBlock:^(NSString *key, id header, BOOL *stop) { if (![header isKindOfClass:[NSString class]]) { - RCTLogError( + RCTLogInfo( @"Values of HTTP headers passed must be of type string. " "Value of header '%@' is not a string.", key); @@ -200,11 +200,11 @@ RCT_ENUM_CONVERTER( { NSURL *fileURL = [self NSURL:json]; if (!fileURL.fileURL) { - RCTLogError(@"URI must be a local file, '%@' isn't.", fileURL); + RCTLogInfo(@"URI must be a local file, '%@' isn't.", fileURL); return nil; } if (![[NSFileManager defaultManager] fileExistsAtPath:fileURL.path]) { - RCTLogError(@"File '%@' could not be found.", fileURL); + RCTLogInfo(@"File '%@' could not be found.", fileURL); return nil; } return fileURL; @@ -225,7 +225,7 @@ RCT_ENUM_CONVERTER( }); NSDate *date = [formatter dateFromString:json]; if (!date) { - RCTLogError( + RCTLogInfo( @"JSON String '%@' could not be interpreted as a date. " "Expected format: YYYY-MM-DD'T'HH:mm:ss.sssZ", json); @@ -242,7 +242,7 @@ RCT_ENUM_CONVERTER( if ([json isKindOfClass:[NSString class]]) { NSLocale *locale = [[NSLocale alloc] initWithLocaleIdentifier:json]; if (!locale) { - RCTLogError(@"JSON String '%@' could not be interpreted as a valid locale. ", json); + RCTLogInfo(@"JSON String '%@' could not be interpreted as a valid locale. ", json); } return locale; } else if (json) { @@ -267,15 +267,15 @@ NSNumber *RCTConvertEnumValue(const char *typeName, NSDictionary *mapping, NSNum if ([allValues containsObject:json] || [json isEqual:defaultValue]) { return json; } - RCTLogError(@"Invalid %s '%@'. should be one of: %@", typeName, json, allValues); + RCTLogInfo(@"Invalid %s '%@'. should be one of: %@", typeName, json, allValues); return defaultValue; } if (RCT_DEBUG && ![json isKindOfClass:[NSString class]]) { - RCTLogError(@"Expected NSNumber or NSString for %s, received %@: %@", typeName, [json classForCoder], json); + RCTLogInfo(@"Expected NSNumber or NSString for %s, received %@: %@", typeName, [json classForCoder], json); } id value = mapping[json]; if (RCT_DEBUG && !value && [json description].length > 0) { - RCTLogError( + RCTLogInfo( @"Invalid %s '%@'. should be one of: %@", typeName, json, @@ -541,7 +541,7 @@ static void convertCGStruct(const char *type, NSArray *fields, CGFloat *result, NSUInteger count = fields.count; if ([json isKindOfClass:[NSArray class]]) { if (RCT_DEBUG && [json count] != count) { - RCTLogError( + RCTLogInfo( @"Expected array with count %llu, but count is %llu: %@", (unsigned long long)count, (unsigned long long)[json count], @@ -1295,7 +1295,7 @@ RCT_ENUM_CONVERTER( } if (!CGSizeEqualToSize(imageSource.size, CGSizeZero) && !CGSizeEqualToSize(imageSource.size, image.size)) { - RCTLogError( + RCTLogInfo( @"Image source %@ size %@ does not match loaded image size %@.", URL.path.lastPathComponent, NSStringFromCGSize(imageSource.size), diff --git a/React/Views/RCTConvert+Transform.m b/React/Views/RCTConvert+Transform.m index 1d2b99b3a05..348d4ec4abe 100644 --- a/React/Views/RCTConvert+Transform.m +++ b/React/Views/RCTConvert+Transform.m @@ -138,7 +138,7 @@ static const NSUInteger kMatrixArrayLength = 4 * 4; transform = CATransform3DConcat(next, transform); } else { - RCTLogError(@"Unsupported transform type for a CATransform3D: %@.", property); + RCTLogInfo(@"Unsupported transform type for a CATransform3D: %@.", property); } } return transform; diff --git a/React/Views/RCTFont.mm b/React/Views/RCTFont.mm index 4f75304ee76..9cbb2013ea4 100644 --- a/React/Views/RCTFont.mm +++ b/React/Views/RCTFont.mm @@ -332,7 +332,7 @@ typedef NSDictionary RCTFontVariantDescriptor; }); RCTFontVariantDescriptor *value = mapping[json]; if (RCT_DEBUG && !value && [json description].length > 0) { - RCTLogError( + RCTLogInfo( @"Invalid RCTFontVariantDescriptor '%@'. should be one of: %@", json, [[mapping allKeys] sortedArrayUsingSelector:@selector(caseInsensitiveCompare:)]); diff --git a/React/Views/RCTView.m b/React/Views/RCTView.m index 6d7583395e3..eb30e9da667 100644 --- a/React/Views/RCTView.m +++ b/React/Views/RCTView.m @@ -212,7 +212,7 @@ RCT_NOT_IMPLEMENTED(-(instancetype)initWithCoder : unused) case RCTPointerEventsBoxNone: return hitSubview; default: - RCTLogError(@"Invalid pointer-events specified %lld on %@", (long long)_pointerEvents, self); + RCTLogInfo(@"Invalid pointer-events specified %lld on %@", (long long)_pointerEvents, self); return hitSubview ?: hitView; } } diff --git a/React/Views/RCTViewManager.m b/React/Views/RCTViewManager.m index a866b6f7489..8c97b298879 100644 --- a/React/Views/RCTViewManager.m +++ b/React/Views/RCTViewManager.m @@ -266,7 +266,7 @@ RCT_CUSTOM_VIEW_PROPERTY(pointerEvents, RCTPointerEvents, RCTView) view.userInteractionEnabled = NO; break; default: - RCTLogError(@"UIView base class does not support pointerEvent value: %@", json); + RCTLogInfo(@"UIView base class does not support pointerEvent value: %@", json); } } RCT_CUSTOM_VIEW_PROPERTY(removeClippedSubviews, BOOL, RCTView)