From 768bca1b355d9811c3f12e9cdd452356b8ee29a9 Mon Sep 17 00:00:00 2001 From: Konstantin Pelz Date: Wed, 30 Oct 2024 11:05:43 +0100 Subject: [PATCH] #2663 Add missing .end() to response --- .../main/java/io/vertx/ext/web/impl/RoutingContextImpl.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/vertx-web/src/main/java/io/vertx/ext/web/impl/RoutingContextImpl.java b/vertx-web/src/main/java/io/vertx/ext/web/impl/RoutingContextImpl.java index cfa0fc71be..03a60341a0 100644 --- a/vertx-web/src/main/java/io/vertx/ext/web/impl/RoutingContextImpl.java +++ b/vertx-web/src/main/java/io/vertx/ext/web/impl/RoutingContextImpl.java @@ -160,7 +160,9 @@ private void checkHandleNoMatch() { .putHeader(HttpHeaderNames.ALLOW, allowedMethods.stream().map(HttpMethod::name).collect(Collectors.joining(","))).end(); } else if (this.request().method() != HttpMethod.HEAD && matchFailure == 415) { // In case of a 415, send a header with the accepted content types - this.response().putHeader(HttpHeaderNames.ACCEPT, allowedContentTypes.stream().map(MIMEHeader::mediaType).collect(Collectors.joining(", "))); + this.response() + .putHeader(HttpHeaderNames.ACCEPT, allowedContentTypes.stream().map(MIMEHeader::mediaType).collect(Collectors.joining(", "))) + .end(); } else { this.response().end(); }