Remove unnecessary conversions
Motivation: In a `HttpConversionUtil#toHttp2Headers` a status code conversion can be replaced with using `HttpResponseStatus#codeAsText` method. Modifications: Apply `HttpResponseStatus#codeAsText` method. Result: Less allocations.
This commit is contained in:
parent
6b25909f6b
commit
8f8be31226
@ -361,7 +361,7 @@ public final class HttpConversionUtil {
|
|||||||
}
|
}
|
||||||
} else if (in instanceof HttpResponse) {
|
} else if (in instanceof HttpResponse) {
|
||||||
HttpResponse response = (HttpResponse) in;
|
HttpResponse response = (HttpResponse) in;
|
||||||
out.status(new AsciiString(Integer.toString(response.status().code())));
|
out.status(response.status().codeAsText());
|
||||||
}
|
}
|
||||||
|
|
||||||
// Add the HTTP headers which have not been consumed above
|
// Add the HTTP headers which have not been consumed above
|
||||||
|
Loading…
Reference in New Issue
Block a user