Skip to content

Commit 7b35c85

Browse files
JoeCquptkongzhi.jy
authored andcommitted
fix format
1 parent c2ec843 commit 7b35c85

File tree

2 files changed

+8
-5
lines changed

2 files changed

+8
-5
lines changed

netty/src/main/java/io/grpc/netty/NettyServerHandler.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -872,7 +872,7 @@ public boolean visit(Http2Stream stream) throws Http2Exception {
872872
}
873873

874874
private void respondWithHttpError(
875-
ChannelHandlerContext ctx, int streamId, int code, Status.Code statusCode, String msg) {
875+
ChannelHandlerContext ctx, int streamId, int code, Status.Code statusCode, String msg) {
876876
respondWithHttpError(ctx, streamId, code, statusCode, msg, EmptyHttp2Headers.INSTANCE);
877877
}
878878

okhttp/src/main/java/io/grpc/okhttp/OkHttpServerTransport.java

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -774,7 +774,8 @@ public void headers(boolean outFinished,
774774
}
775775

776776
if (!POST_METHOD.equals(httpMethod)) {
777-
List<Header> extraHeaders = Lists.newArrayList(new Header(ByteString.encodeUtf8("allow"), POST_METHOD));
777+
List<Header> extraHeaders = Lists.newArrayList(new Header(ByteString.encodeUtf8("allow"),
778+
POST_METHOD));
778779
respondWithHttpError(streamId, inFinished, 405, Status.Code.INTERNAL,
779780
"HTTP Method is not supported: " + asciiString(httpMethod), extraHeaders);
780781
return;
@@ -1068,12 +1069,14 @@ private void streamError(int streamId, ErrorCode errorCode, String reason) {
10681069
}
10691070

10701071
private void respondWithHttpError(
1071-
int streamId, boolean inFinished, int httpCode, Status.Code statusCode, String msg) {
1072-
respondWithHttpError(streamId, inFinished, httpCode, statusCode, msg, Collections.emptyList());
1072+
int streamId, boolean inFinished, int httpCode, Status.Code statusCode, String msg) {
1073+
respondWithHttpError(streamId, inFinished, httpCode, statusCode, msg,
1074+
Collections.emptyList());
10731075
}
10741076

10751077
private void respondWithHttpError(
1076-
int streamId, boolean inFinished, int httpCode, Status.Code statusCode, String msg, List<Header> extraHeaders) {
1078+
int streamId, boolean inFinished, int httpCode, Status.Code statusCode, String msg,
1079+
List<Header> extraHeaders) {
10771080
Metadata metadata = new Metadata();
10781081
metadata.put(InternalStatus.CODE_KEY, statusCode.toStatus());
10791082
metadata.put(InternalStatus.MESSAGE_KEY, msg);

0 commit comments

Comments
 (0)