aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorGravatar Muxi Yan <mxyan@google.com>2018-10-19 09:26:38 -0700
committerGravatar Muxi Yan <mxyan@google.com>2018-10-19 09:26:38 -0700
commit75f8727a3e35ac3db8a3957d9318f2dfdd798e7f (patch)
tree5868fc932fbcca057e20985f1aee0e5b66a403f3
parent56d605230f2d8c2ddb5670e8d0f2ede6c2aca4d1 (diff)
NSString == nil -> NSString.length == 0
-rw-r--r--src/objective-c/GRPCClient/private/GRPCWrappedCall.m2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/objective-c/GRPCClient/private/GRPCWrappedCall.m b/src/objective-c/GRPCClient/private/GRPCWrappedCall.m
index 1c03bc9efd..a7c50a1751 100644
--- a/src/objective-c/GRPCClient/private/GRPCWrappedCall.m
+++ b/src/objective-c/GRPCClient/private/GRPCWrappedCall.m
@@ -247,7 +247,7 @@
- (instancetype)initWithHost:(NSString *)host
path:(NSString *)path
callOptions:(GRPCCallOptions *)callOptions {
- if (!path || !host) {
+ if (host.length == 0 || path.length == 0) {
[NSException raise:NSInvalidArgumentException format:@"path and host cannot be nil."];
}