From b73d735669565414f510a7f6e52ec9dd3baee330 Mon Sep 17 00:00:00 2001 From: Sumudu-Sahan Date: Mon, 6 Jan 2025 11:42:24 +0530 Subject: [PATCH] Fixed the throwing null value issue for subscription update workflow type. --- .../rest/api/admin/v1/utils/mappings/WorkflowMappingUtil.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/components/apimgt/org.wso2.carbon.apimgt.rest.api.admin.v1/src/main/java/org/wso2/carbon/apimgt/rest/api/admin/v1/utils/mappings/WorkflowMappingUtil.java b/components/apimgt/org.wso2.carbon.apimgt.rest.api.admin.v1/src/main/java/org/wso2/carbon/apimgt/rest/api/admin/v1/utils/mappings/WorkflowMappingUtil.java index dd8c9c6f5c7d..0975336de075 100644 --- a/components/apimgt/org.wso2.carbon.apimgt.rest.api.admin.v1/src/main/java/org/wso2/carbon/apimgt/rest/api/admin/v1/utils/mappings/WorkflowMappingUtil.java +++ b/components/apimgt/org.wso2.carbon.apimgt.rest.api.admin.v1/src/main/java/org/wso2/carbon/apimgt/rest/api/admin/v1/utils/mappings/WorkflowMappingUtil.java @@ -82,6 +82,8 @@ public static WorkflowInfoDTO fromWorkflowsToInfoDTO(Workflow workflow) { workflowInfoDTO.setWorkflowType(WorkflowInfoDTO.WorkflowTypeEnum.API_PRODUCT_STATE); } else if (workflow.getWorkflowType().equals("AM_REVISION_DEPLOYMENT")) { workflowInfoDTO.setWorkflowType(WorkflowInfoDTO.WorkflowTypeEnum.REVISION_DEPLOYMENT); + } else if (workflow.getWorkflowType().equals("AM_SUBSCRIPTION_UPDATE")) { + workflowInfoDTO.setWorkflowType(WorkflowInfoDTO.WorkflowTypeEnum.SUBSCRIPTION_UPDATE); } workflowInfoDTO.setWorkflowStatus(WorkflowInfoDTO.WorkflowStatusEnum.valueOf(workflow.getStatus().toString())); workflowInfoDTO.setCreatedTime(workflow.getCreatedTime());