Remove length check in GRPCCall for backwards compatibility

pull/16190/head
Muxi Yan 6 years ago
parent a8c4eb7d27
commit abe4aae400
  1. 3
      src/objective-c/GRPCClient/GRPCCall.m

@ -391,7 +391,8 @@ const char *kCFStreamVarName = "grpc_cfstream";
callSafety:(GRPCCallSafety)safety
requestsWriter:(GRXWriter *)requestWriter
callOptions:(GRPCCallOptions *)callOptions {
if (host.length == 0 || path.length == 0) {
// Purposely using pointer rather than length ([host length] == 0) for backwards compatibility.
if (!host || !path) {
[NSException raise:NSInvalidArgumentException
format:@"Neither host nor path can be nil or empty."];
}

Loading…
Cancel
Save