You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@myfaces.apache.org by mm...@apache.org on 2006/09/22 15:14:18 UTC

svn commit: r448915 - /myfaces/core/trunk/api/src/main/java/javax/faces/webapp/UIComponentTag.java

Author: mmarinschek
Date: Fri Sep 22 06:14:18 2006
New Revision: 448915

URL: http://svn.apache.org/viewvc?view=rev&rev=448915
Log:
Changed the message the users sees when facesContext is null

Modified:
    myfaces/core/trunk/api/src/main/java/javax/faces/webapp/UIComponentTag.java

Modified: myfaces/core/trunk/api/src/main/java/javax/faces/webapp/UIComponentTag.java
URL: http://svn.apache.org/viewvc/myfaces/core/trunk/api/src/main/java/javax/faces/webapp/UIComponentTag.java?view=diff&rev=448915&r1=448914&r2=448915
==============================================================================
--- myfaces/core/trunk/api/src/main/java/javax/faces/webapp/UIComponentTag.java (original)
+++ myfaces/core/trunk/api/src/main/java/javax/faces/webapp/UIComponentTag.java Fri Sep 22 06:14:18 2006
@@ -920,7 +920,11 @@
 
         if(facesContext == null)
         {
-            log.error("Faces context not found. getResponseWriter will fail. Check if the FacesServlet has been initialized at all in your web.xml.");
+            throw new FacesException("Faces context not found. getResponseWriter will fail. "+
+                    "Check if the FacesServlet has been initialized at all in your web.xml configuration file"+
+                    "and if you are accessing your jsf-pages through the correct mapping. E.g.: if your FacesServlet is mapped to "+
+                    " *.jsf, you need to access your pages as 'sample.jsf'. If you'd try to access 'sample.jsp', you'd get this error-message."                    
+                    );
         }
 
         _writer = facesContext.getResponseWriter();