diff --git a/impl/src/main/java/org/apache/myfaces/application/ApplicationImpl.java b/impl/src/main/java/org/apache/myfaces/application/ApplicationImpl.java index 2701e2bed5..847344615b 100755 --- a/impl/src/main/java/org/apache/myfaces/application/ApplicationImpl.java +++ b/impl/src/main/java/org/apache/myfaces/application/ApplicationImpl.java @@ -588,7 +588,6 @@ public final void addELContextListener(final ELContextListener listener) public void publishEvent(FacesContext facesContext, Class systemEventClass, Class sourceBaseType, Object source) { - checkNull(facesContext, "facesContext"); checkNull(systemEventClass, "systemEventClass"); checkNull(source, "source"); @@ -647,7 +646,6 @@ public void publishEvent(FacesContext facesContext, Class @Override public void publishEvent(FacesContext facesContext, Class systemEventClass, Object source) { - checkNull(source, "source"); publishEvent(facesContext, systemEventClass, source.getClass(), source); } diff --git a/impl/src/main/java/org/apache/myfaces/cdi/JsfArtifactProducer.java b/impl/src/main/java/org/apache/myfaces/cdi/JsfArtifactProducer.java index bfa82f3a36..07be72606a 100644 --- a/impl/src/main/java/org/apache/myfaces/cdi/JsfArtifactProducer.java +++ b/impl/src/main/java/org/apache/myfaces/cdi/JsfArtifactProducer.java @@ -31,6 +31,7 @@ import jakarta.faces.annotation.RequestParameterValuesMap; import jakarta.faces.annotation.SessionMap; import jakarta.faces.annotation.ViewMap; +import jakarta.faces.application.Application; import jakarta.faces.application.ResourceHandler; import jakarta.faces.component.UIViewRoot; import jakarta.faces.context.ExternalContext; @@ -45,9 +46,9 @@ public class JsfArtifactProducer @Produces @Named("application") @ApplicationScoped - public Object getApplication() + public Application getApplication() { - return FacesContext.getCurrentInstance().getExternalContext().getContext(); + return FacesContext.getCurrentInstance().getApplication(); } @Produces diff --git a/impl/src/main/java/org/apache/myfaces/context/servlet/ServletExternalContextImpl.java b/impl/src/main/java/org/apache/myfaces/context/servlet/ServletExternalContextImpl.java index d4ea3ff05a..755edf4044 100755 --- a/impl/src/main/java/org/apache/myfaces/context/servlet/ServletExternalContextImpl.java +++ b/impl/src/main/java/org/apache/myfaces/context/servlet/ServletExternalContextImpl.java @@ -590,10 +590,6 @@ public void redirect(final String url) throws IOException PartialViewContext partialViewContext = facesContext.getPartialViewContext(); if (partialViewContext.isPartialRequest()) { - if (_servletResponse instanceof HttpServletResponse && facesContext.getResponseComplete()) - { - throw new IllegalStateException(); - } PartialResponseWriter writer = partialViewContext.getPartialResponseWriter(); this.setResponseContentType("text/xml"); this.setResponseCharacterEncoding("UTF-8"); diff --git a/shared/src/main/java/org/apache/myfaces/shared/application/FacesServletMappingUtils.java b/shared/src/main/java/org/apache/myfaces/shared/application/FacesServletMappingUtils.java index 45f214882a..9896b6d316 100644 --- a/shared/src/main/java/org/apache/myfaces/shared/application/FacesServletMappingUtils.java +++ b/shared/src/main/java/org/apache/myfaces/shared/application/FacesServletMappingUtils.java @@ -291,7 +291,7 @@ else if (allowExactMatch && mapping.startsWith("/") && mapping.equals(servletPat } if (mapping.equals(servletPath)) { - return FacesServletMapping.createExactMapping(mapping); // MYFACES-4524 + return FacesServletMapping.createPrefixMapping(mapping); } } }