From 18583af6b4ecf80c4e9ed653c56f3c3e27eaa8c5 Mon Sep 17 00:00:00 2001 From: sinthuja Date: Wed, 29 Mar 2017 23:07:18 +0530 Subject: [PATCH] Fixing the case where multiple tags were passed for searching the APIs. --- .../extension/APIManagementProviderServiceImpl.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/components/apimgt-extensions/org.wso2.carbon.apimgt.application.extension/src/main/java/org/wso2/carbon/apimgt/application/extension/APIManagementProviderServiceImpl.java b/components/apimgt-extensions/org.wso2.carbon.apimgt.application.extension/src/main/java/org/wso2/carbon/apimgt/application/extension/APIManagementProviderServiceImpl.java index fa473a4133..070a9f6402 100644 --- a/components/apimgt-extensions/org.wso2.carbon.apimgt.application.extension/src/main/java/org/wso2/carbon/apimgt/application/extension/APIManagementProviderServiceImpl.java +++ b/components/apimgt-extensions/org.wso2.carbon.apimgt.application.extension/src/main/java/org/wso2/carbon/apimgt/application/extension/APIManagementProviderServiceImpl.java @@ -153,7 +153,9 @@ public class APIManagementProviderServiceImpl implements APIManagementProviderSe subscription.setApiIdentifier(id); subscription.setApplicationId(application.getApplicationId()); subscription.tier(ApiApplicationConstants.DEFAULT_TIER); - needToSubscribe.add(subscription); + if (!needToSubscribe.contains(subscription)){ + needToSubscribe.add(subscription); + } } } }