Commits

Anonymous committed 2ae139b

Remove unused imports from underway.jsp and handle potential NPE in memory store

  • Participants
  • Parent commits 2694931

Comments (0)

Files changed (3)

File src/java/com/opensymphony/workflow/Workflow.aegis.xml

 <mappings>
   <mapping>
     <method name="initialize">
-      <parameter index="2" keyType="java.lang.String" componentType="java.lang.String"/>
+      <parameter index="0" mappedName="workflowName"/>
+      <parameter index="1" mappedName="initialAction"/>
+      <parameter index="2" keyType="java.lang.String" componentType="java.lang.String" mappedName="inputs"/>
     </method>
     <method name="canInitialize">
-      <parameter index="2" keyType="java.lang.String" componentType="java.lang.String"/>
+      <parameter index="2" keyType="java.lang.String" componentType="java.lang.String" mappedName="inputs"/>
     </method>
     <method name="getAvailableActions">
-      <parameter index="1" keyType="java.lang.String" componentType="java.lang.String"/>
+      <parameter index="1" keyType="java.lang.String" componentType="java.lang.String" mappedName="inputs"/>
     </method>
     <method name="doAction">
-      <parameter index="2" keyType="java.lang.String" componentType="java.lang.String"/>
+      <parameter index="2" keyType="java.lang.String" componentType="java.lang.String" mappedName="inputs"/>
     </method>
     <method name="query">
       <return-type componentType="java.lang.Long"/>

File src/java/com/opensymphony/workflow/spi/memory/MemoryWorkflowStore.java

             steps = (List) historyStepsCache.get(entryId);
         }
 
+        if (steps == null) {
+            return false;
+        }
+
         switch (field) {
         case WorkflowQuery.ACTION:
 

File src/webapp/underway.jsp

-<%@ page import="com.opensymphony.user.User,
-                 com.opensymphony.workflow.Workflow,
+<%@ page import="com.opensymphony.workflow.Workflow,
                  com.opensymphony.workflow.basic.BasicWorkflow,
-                 com.opensymphony.workflow.spi.Step,
                  java.util.*,
-                 com.opensymphony.workflow.loader.WorkflowDescriptor,
-                 com.opensymphony.workflow.loader.ActionDescriptor,
                  com.opensymphony.workflow.query.WorkflowQuery"%>
 <%
     Workflow wf = new BasicWorkflow((String) session.getAttribute("username"));