You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@myfaces.apache.org by lu...@apache.org on 2010/06/24 01:57:20 UTC
svn commit: r957389 -
/myfaces/core/trunk/impl/src/main/java/org/apache/myfaces/application/ApplicationImpl.java
Author: lu4242
Date: Wed Jun 23 23:57:20 2010
New Revision: 957389
URL: http://svn.apache.org/viewvc?rev=957389&view=rev
Log:
MYFACES-2766 Check StartupFacesContextImpl in ApplicationImpl (thanks to Martin Koci for provide this patch)
Modified:
myfaces/core/trunk/impl/src/main/java/org/apache/myfaces/application/ApplicationImpl.java
Modified: myfaces/core/trunk/impl/src/main/java/org/apache/myfaces/application/ApplicationImpl.java
URL: http://svn.apache.org/viewvc/myfaces/core/trunk/impl/src/main/java/org/apache/myfaces/application/ApplicationImpl.java?rev=957389&r1=957388&r2=957389&view=diff
==============================================================================
--- myfaces/core/trunk/impl/src/main/java/org/apache/myfaces/application/ApplicationImpl.java (original)
+++ myfaces/core/trunk/impl/src/main/java/org/apache/myfaces/application/ApplicationImpl.java Wed Jun 23 23:57:20 2010
@@ -260,7 +260,7 @@ public class ApplicationImpl extends App
@Override
public final void addELResolver(final ELResolver resolver)
{
- if (FacesContext.getCurrentInstance() != null)
+ if (isFirstRequestProcessed())
{
throw new IllegalStateException("It is illegal to add a resolver after the first request is processed");
}
@@ -829,7 +829,7 @@ public class ApplicationImpl extends App
{
checkNull(variableResolver, "variableResolver");
- if (getFaceContext() != null)
+ if (isFirstRequestProcessed())
{
throw new IllegalStateException("variableResolver must be defined before request processing");
}