webwork/src/main/webwork/dispatcher ConfigurationViewMapping.java,1.5,1.6

[email protected] Mon, 17 Jun 2002 06:29:15 -0700
Newsgroups gmane.comp.java.webwork.cvs
Message-ID <[email protected]>
Update of /cvsroot/webwork/webwork/src/main/webwork/dispatcher
In directory usw-pr-cvs1:/tmp/cvs-serv21202

Modified Files:
	ConfigurationViewMapping.java 
Log Message:
updated to return appropriate error message for attempted view retrieval

Index: ConfigurationViewMapping.java
===================================================================
RCS file: /cvsroot/webwork/webwork/src/main/webwork/dispatcher/ConfigurationViewMapping.java,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -d -r1.5 -r1.6
--- ConfigurationViewMapping.java	15 Jun 2002 14:22:17 -0000	1.5
+++ ConfigurationViewMapping.java	17 Jun 2002 13:29:13 -0000	1.6
@@ -81,9 +81,13 @@
       } catch (IllegalArgumentException ex)
       {
          // No view found
-         if (aViewName.equals(Action.INPUT))
-            return getView(anActionName, Action.ERROR);
-
+         if (aViewName.equals(Action.INPUT)) {
+            try {
+               return getView(anActionName, Action.ERROR);
+            } catch (IllegalArgumentException ex2) {
+               throw new IllegalArgumentException("No 'input' view found for action '"+anActionName+"'");
+            }
+         }
          throw new IllegalArgumentException("No '"+aViewName+"' view found for action '"+anActionName+"'");
       }
    }



_______________________________________________________________

Sponsored by:
ThinkGeek at http://www.ThinkGeek.com/