Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: resteasy/resteasy
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: main
Choose a base ref
...
head repository: jimma/Resteasy
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: master
Choose a head ref
Can’t automatically merge. Don’t worry, you can still create the pull request.
  • 1 commit
  • 1 file changed
  • 1 contributor

Commits on Feb 2, 2021

  1. Copy the full SHA
    0c7a5d1 View commit details
Showing with 8 additions and 9 deletions.
  1. +8 −9 ...rc/main/java/org/jboss/resteasy/plugins/interceptors/MessageSanitizerContainerResponseFilter.java
Original file line number Diff line number Diff line change
@@ -30,17 +30,16 @@ public class MessageSanitizerContainerResponseFilter implements ContainerRespons
@Override
public void filter(ContainerRequestContext requestContext,
ContainerResponseContext responseContext) throws IOException {

ResteasyDeployment deployment = ResteasyContext.getContextData(ResteasyDeployment.class);
if (deployment != null)
{
Boolean disable = (Boolean) deployment.getProperty(ResteasyContextParameters.RESTEASY_DISABLE_HTML_SANITIZER);
if (disable != null && disable)
if (HttpResponseCodes.SC_BAD_REQUEST == responseContext.getStatus()) {
ResteasyDeployment deployment = ResteasyContext.getContextData(ResteasyDeployment.class);
if (deployment != null)
{
return;
Boolean disable = (Boolean) deployment.getProperty(ResteasyContextParameters.RESTEASY_DISABLE_HTML_SANITIZER);
if (disable != null && disable)
{
return;
}
}
}
if (HttpResponseCodes.SC_BAD_REQUEST == responseContext.getStatus()) {
Object entity = responseContext.getEntity();
if (entity != null && entity instanceof String) {
List<Object> contentTypes = responseContext.getHeaders().get("Content-Type");