Skip to content

Commit

Permalink
Changing Error to Warning
Browse files Browse the repository at this point in the history
Summary:
As discussed with @nicklockwood in the issue facebook#1780, the error should be changed to a warning to not break fetch() to send a POST to a remote API without wanting to parse the reply. E.g. google sends back an empty 1x1px gif when POSTing something to google analytics.
Closes facebook#1860
Github Author: "philipp.krone" <[email protected]>
  • Loading branch information
PhilippKrone committed Jul 8, 2015
1 parent bfbc280 commit 4b5b952
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Libraries/Network/RCTNetworking.m
Original file line number Diff line number Diff line change
Expand Up @@ -381,7 +381,7 @@ - (void)sendData:(NSData *)data forRequestToken:(id)requestToken

NSString *responseText = [[NSString alloc] initWithData:data encoding:encoding];
if (!responseText && data.length) {
RCTLogError(@"Received data was invalid.");
RCTLogWarn(@"Received data was invalid.");
return;
}

Expand Down

0 comments on commit 4b5b952

Please sign in to comment.