mirror of https://github.com/grpc/grpc-node.git
Do not overwrite error 'metadata' if already specified by caller.
This commit is contained in:
parent
fa20c5e565
commit
7e1d20fec1
|
@ -455,7 +455,9 @@ export class Http2ServerCallStream<
|
||||||
}
|
}
|
||||||
|
|
||||||
if (err) {
|
if (err) {
|
||||||
err.metadata = metadata;
|
if (!err.hasOwnProperty('metadata')) {
|
||||||
|
err.metadata = metadata;
|
||||||
|
}
|
||||||
this.sendError(err);
|
this.sendError(err);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue