Skip to content

Commit

Permalink
fix error message about content-types
Browse files Browse the repository at this point in the history
Signed-off-by: Josh Humphries <2035234+jhump@users.noreply.github.com>
  • Loading branch information
jhump committed Sep 13, 2024
1 parent 2a694ed commit 2358f3a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions duplex_http_call.go
Original file line number Diff line number Diff line change
Expand Up @@ -168,6 +168,8 @@ func (d *duplexHTTPCall) CloseWrite() error {
// response to read from.
if d.requestSent.CompareAndSwap(false, true) {
go d.makeRequest()
// We never setup a request body, so it's effectively already closed.
// So nothing else to do.
return nil
}
// The user calls CloseWrite to indicate that they're done sending data. It's
Expand Down
2 changes: 1 addition & 1 deletion protocol_connect.go
Original file line number Diff line number Diff line change
Expand Up @@ -1408,7 +1408,7 @@ func connectValidateStreamResponseContentType(requestCodecName string, streamTyp
CodeUnknown,
"invalid content-type: %q; expecting %q",
responseContentType,
connectUnaryContentTypePrefix+requestCodecName,
connectStreamingContentTypePrefix+requestCodecName,
)
}
responseCodecName := connectCodecFromContentType(
Expand Down

0 comments on commit 2358f3a

Please sign in to comment.