Author: niallp
Date: Tue Apr 26 12:06:27 2005
New Revision: 164860

URL: http://svn.apache.org/viewcvs?rev=164860&view=rev
Log:
Port fix for PR #16653 to 1.2.x branch - Add a check for missing 
ValidatorResources and throw more informative exception

Modified:
    
struts/core/branches/STRUTS_1_2_BRANCH/src/share/org/apache/struts/taglib/html/JavascriptValidatorTag.java

Modified: 
struts/core/branches/STRUTS_1_2_BRANCH/src/share/org/apache/struts/taglib/html/JavascriptValidatorTag.java
URL: 
http://svn.apache.org/viewcvs/struts/core/branches/STRUTS_1_2_BRANCH/src/share/org/apache/struts/taglib/html/JavascriptValidatorTag.java?rev=164860&r1=164859&r2=164860&view=diff
==============================================================================
--- 
struts/core/branches/STRUTS_1_2_BRANCH/src/share/org/apache/struts/taglib/html/JavascriptValidatorTag.java
 (original)
+++ 
struts/core/branches/STRUTS_1_2_BRANCH/src/share/org/apache/struts/taglib/html/JavascriptValidatorTag.java
 Tue Apr 26 12:06:27 2005
@@ -369,6 +369,12 @@
                 ValidatorPlugIn.VALIDATOR_KEY + config.getPrefix(),
                 PageContext.APPLICATION_SCOPE);
 
+        if (resources == null) {
+            throw new JspException(
+                "ValidatorResources not found in application scope under key 
\"" 
+                + ValidatorPlugIn.VALIDATOR_KEY + config.getPrefix() + "\"");
+        }        
+
         Locale locale = TagUtils.getInstance().getUserLocale(this.pageContext, 
null);
 
         Form form = resources.getForm(locale, formName);



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to