Skip to content

Commit

Permalink
🐛 fixed hook response not write
Browse files Browse the repository at this point in the history
  • Loading branch information
hellokaton committed Jul 3, 2018
1 parent c9f71a5 commit 7f9982a
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions src/main/java/com/blade/server/netty/RouteMethodHandler.java
Original file line number Diff line number Diff line change
Expand Up @@ -314,15 +314,13 @@ public void handle(ChannelHandlerContext ctx, Request request, Response response

// execution middleware
if (hasMiddleware && !invokeMiddleware(routeMatcher.getMiddleware(), context)) {
context.body(EmptyBody.empty());
handleResponse(context.response(), ctx, keepAlive);
return;
}
context.injectParameters();

// web hook before
if (hasBeforeHook && !invokeHook(routeMatcher.getBefore(uri), context)) {
context.body(EmptyBody.empty());
handleResponse(context.response(), ctx, keepAlive);
return;
}
Expand Down

0 comments on commit 7f9982a

Please sign in to comment.