if (target != null) {
try {
String result = null;
if (target instanceof RouteImpl) {
RouteImpl route = ((RouteImpl) target);
Request request = RequestResponseFactory.create(match, httpRequest);
Response response = RequestResponseFactory.create(httpResponse);
req.setDelegate(request);
res.setDelegate(response);
Object element = route.handle(req, res);
result = route.render(element);
// result = element.toString(); // TODO: Remove later when render fixed
}
if (result != null) {
bodyContent = result;
}