Fix usage of subscript access in RKHTTPRequestOperation.m refs #1077

This commit is contained in:
Blake Watters
2012-12-14 07:55:06 -05:00
parent a424908242
commit c75a05a754

View File

@@ -41,7 +41,7 @@ static NSString *RKLogTruncateString(NSString *string)
static dispatch_once_t onceToken;
dispatch_once(&onceToken, ^{
NSDictionary *envVars = [[NSProcessInfo processInfo] environment];
maxMessageLength = RKLogIsStringBlank(envVars[@"RKLogMaxLength"]) ? NSIntegerMax : [envVars[@"RKLogMaxLength"] integerValue];
maxMessageLength = RKLogIsStringBlank([envVars objectForKey:@"RKLogMaxLength"]) ? NSIntegerMax : [[envVars objectForKey:@"RKLogMaxLength"] integerValue];
});
return ([string length] <= maxMessageLength)