Skip to content

Commit 6577c66

Browse files
authored
GrpcWebClientBase: clean up !useUnaryResponse callback args (#1297)
1 parent e11903b commit 6577c66

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

javascript/net/grpc/web/grpcwebclientbase.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -278,8 +278,10 @@ class GrpcWebClientBase {
278278
code: StatusCode.UNKNOWN,
279279
message: 'Incomplete response',
280280
});
281-
} else {
281+
} else if (useUnaryResponse) {
282282
callback(null, responseReceived, null, null, /* unaryResponseReceived= */ true);
283+
} else {
284+
callback(null, responseReceived);
283285
}
284286
}
285287
if (useUnaryResponse) {

0 commit comments

Comments
 (0)