• Phillip Webb's avatar
    Only handle status errors when sendError is called · de48223a
    Phillip Webb authored
    Update ErrorPageFilter to only handle errors when `response.sendError`
    has been called. This should allow custom @ExceptionHandlers to
    completely handle errors and return custom status codes without
    triggering the "Cannot forward to error page" log message.
    
    The Javadoc for sendError states:
    
      "The server defaults to creating the response to look like an
       HTML-formatted server error page containing the specified message"
    
    Where as setStatus states
    
      "This method is used to set the return status code when there is
       no error "
    
    Fixes gh-2745
    de48223a
Name
Last commit
Last update
docs Loading commit data...
eclipse Loading commit data...
spring-boot Loading commit data...
spring-boot-actuator Loading commit data...
spring-boot-autoconfigure Loading commit data...
spring-boot-cli Loading commit data...
spring-boot-dependencies Loading commit data...
spring-boot-deployment-tests Loading commit data...
spring-boot-docs Loading commit data...
spring-boot-full-build Loading commit data...
spring-boot-integration-tests Loading commit data...
spring-boot-parent Loading commit data...
spring-boot-samples Loading commit data...
spring-boot-starters Loading commit data...
spring-boot-tools Loading commit data...
spring-boot-versions Loading commit data...
.gitignore Loading commit data...
.settings-template.xml Loading commit data...
.travis.yml Loading commit data...
CONTRIBUTING.adoc Loading commit data...
LICENSE.txt Loading commit data...
README.adoc Loading commit data...
pom.xml Loading commit data...