Commits

Anonymous committed 2369a8f

don't require an id for ActionTag. Resolves WW-292

git-svn-id: http://svn.opensymphony.com/svn/webwork/trunk@52573baa09-0c28-0410-bef9-dab3c582ae83

Comments (0)

Files changed (2)

src/etc/taglib.tld

         </info>
         <attribute>
             <name>id</name>
-            <required>true</required>
+            <required>false</required>
             <rtexprvalue>true</rtexprvalue>
         </attribute>
         <attribute>

src/java/com/opensymphony/webwork/views/jsp/ActionTag.java

 import com.opensymphony.webwork.dispatcher.ServletDispatcher;
 import com.opensymphony.webwork.dispatcher.SessionMap;
 import com.opensymphony.webwork.views.velocity.Renderer;
-
 import com.opensymphony.xwork.ActionContext;
 import com.opensymphony.xwork.ActionInvocation;
 import com.opensymphony.xwork.ActionProxy;
 import com.opensymphony.xwork.ActionProxyFactory;
-
 import ognl.Ognl;
-
 import org.apache.commons.logging.Log;
 import org.apache.commons.logging.LogFactory;
-
 import org.apache.velocity.context.Context;
 
-import java.io.Writer;
-
-import java.util.HashMap;
-import java.util.Map;
-
 import javax.servlet.ServletConfig;
 import javax.servlet.ServletContext;
 import javax.servlet.http.HttpServletRequest;
 import javax.servlet.http.HttpServletResponse;
 import javax.servlet.jsp.JspException;
 import javax.servlet.jsp.tagext.TagSupport;
+import java.io.Writer;
+import java.util.HashMap;
+import java.util.Map;
 
 
 /**
             log.error("Could not execute action: " + namespace + "/" + name, e);
         }
 
-        ActionContext.getContext().put(getId(), proxy.getAction());
+        if (getId() != null) {
+            ActionContext.getContext().put(getId(), proxy.getAction());
+        }
     }
 }