struts-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bay...@apache.org
Subject svn commit: r504721 - /struts/struts1/trunk/tiles/src/main/java/org/apache/struts/tiles/taglib/ImportAttributeTag.java
Date Wed, 07 Feb 2007 22:22:22 GMT
Author: bayard
Date: Wed Feb  7 14:22:21 2007
New Revision: 504721

URL: http://svn.apache.org/viewvc?view=rev&rev=504721
Log:
Applying the patch from STR-2996. I'm not a Tiles expert, but this seems like a simple one
to me.

Modified:
    struts/struts1/trunk/tiles/src/main/java/org/apache/struts/tiles/taglib/ImportAttributeTag.java

Modified: struts/struts1/trunk/tiles/src/main/java/org/apache/struts/tiles/taglib/ImportAttributeTag.java
URL: http://svn.apache.org/viewvc/struts/struts1/trunk/tiles/src/main/java/org/apache/struts/tiles/taglib/ImportAttributeTag.java?view=diff&rev=504721&r1=504720&r2=504721
==============================================================================
--- struts/struts1/trunk/tiles/src/main/java/org/apache/struts/tiles/taglib/ImportAttributeTag.java
(original)
+++ struts/struts1/trunk/tiles/src/main/java/org/apache/struts/tiles/taglib/ImportAttributeTag.java
Wed Feb  7 14:22:21 2007
@@ -161,13 +161,18 @@
       {
       Object value = compContext.getAttribute(name);
         // Check if value exist and if we must send a runtime exception
-      if( value == null )
-        if(!isErrorIgnored) {
+      if( value == null ) 
+        {
+        if(!isErrorIgnored) 
+          {
           throw new JspException ( "Error - tag importAttribute : property '"+
               name + "' not found in context. Check tag syntax" );
+          }
+        }
+       else 
+        {
+        pageContext.setAttribute(name, value, scope);
         }
-
-      pageContext.setAttribute(name, value, scope);
       }
      else
       { // set all attributes



Mime
View raw message