Skip to content

Loading…

[#1464] http.exposePlayServer setting not checked on 404 #482

Merged
merged 1 commit into from

2 participants

@sammiq

No description provided.

@pepite pepite merged commit dceeeac into playframework:master
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Mar 13, 2012
  1. @sammiq
Showing with 3 additions and 1 deletion.
  1. +3 −1 framework/src/play/server/PlayHandler.java
View
4 framework/src/play/server/PlayHandler.java
@@ -635,7 +635,9 @@ public static void serve404(NotFound e, ChannelHandlerContext ctx, Request reque
Logger.trace("serve404: begin");
}
HttpResponse nettyResponse = new DefaultHttpResponse(HttpVersion.HTTP_1_1, HttpResponseStatus.NOT_FOUND);
- nettyResponse.setHeader(SERVER, signature);
+ if (exposePlayServer) {
+ nettyResponse.setHeader(SERVER, signature);
+ }
nettyResponse.setHeader(CONTENT_TYPE, "text/html");
Map<String, Object> binding = getBindingForErrors(e, false);
Something went wrong with that request. Please try again.