Skip to content

Commit

Permalink
PR #12208 - changes from review
Browse files Browse the repository at this point in the history
Signed-off-by: Lachlan Roberts <lachlan.p.roberts@gmail.com>
  • Loading branch information
lachlan-roberts committed Sep 2, 2024
1 parent 96a0468 commit 4164ab7
Showing 1 changed file with 3 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,6 @@
import jakarta.servlet.descriptor.TaglibDescriptor;
import jakarta.servlet.http.HttpServlet;
import jakarta.servlet.http.HttpServletRequest;
import jakarta.servlet.http.HttpServletResponse;
import jakarta.servlet.http.HttpSessionActivationListener;
import jakarta.servlet.http.HttpSessionAttributeListener;
import jakarta.servlet.http.HttpSessionBindingListener;
Expand Down Expand Up @@ -1191,13 +1190,9 @@ protected ContextResponse wrapResponse(ContextRequest request, Response response
protected boolean handleByContextHandler(String pathInContext, ContextRequest request, Response response, Callback callback)
{
boolean initialDispatch = request instanceof ServletContextRequest;
if (initialDispatch && isProtectedTarget(pathInContext))
{
Response.writeError(request, response, callback, HttpServletResponse.SC_NOT_FOUND, null);
return true;
}

return false;
if (!initialDispatch)
return false;
return super.handleByContextHandler(pathInContext, request, response, callback);
}

@Override
Expand Down

0 comments on commit 4164ab7

Please sign in to comment.