Skip to content

Commit

Permalink
Merge pull request #455 from candrews/patch-5
Browse files Browse the repository at this point in the history
Exceptions inside includes should propogate up
  • Loading branch information
lhotari committed Jul 27, 2014
2 parents d8c736d + 8a09ff7 commit 3333ea7
Showing 1 changed file with 4 additions and 0 deletions.
Expand Up @@ -347,13 +347,17 @@ public Locale getLocale() {
}
}
catch (ModelAndViewDefiningException ex) {
// Exceptions inside includes should propogate up so the original dispatcher handles the exception
if(WebUtils.isIncludeRequest(request)) throw ex;
handlerException = ex;
if (logger.isDebugEnabled()) {
logger.debug("ModelAndViewDefiningException encountered", ex);
}
mv = ex.getModelAndView();
}
catch (Exception ex) {
// Exceptions inside includes should propogate up so the original dispatcher handles the exception
if(WebUtils.isIncludeRequest(request)) throw ex;
handlerException = ex;
Object handler = (mappedHandler != null ? mappedHandler.getHandler() : null);
mv = processHandlerException(request, response, handler, ex);
Expand Down

0 comments on commit 3333ea7

Please sign in to comment.