mirror of
https://repository.entgra.net/community/device-mgt-core.git
synced 2025-10-06 02:01:45 +00:00
Add minor fixes in application registration flow
This commit is contained in:
commit
2ecfc5c274
@ -112,12 +112,14 @@ public class APIManagementProviderServiceImpl implements APIManagementProviderSe
|
||||
}
|
||||
|
||||
Map<String, APIInfo> uniqueApiSet = new HashMap<>();
|
||||
for (String tag : tags) {
|
||||
Map<String, String> queryParams = new HashMap<>();
|
||||
queryParams.put("tag", tag);
|
||||
if (tags != null) {
|
||||
for (String tag : tags) {
|
||||
Map<String, String> queryParams = new HashMap<>();
|
||||
queryParams.put("tag", tag);
|
||||
|
||||
APIInfo[] apiInfos = consumerRESTAPIServices.getAllApis(apiApplicationInfo, queryParams, headerParams);
|
||||
Arrays.stream(apiInfos).forEach(apiInfo -> uniqueApiSet.putIfAbsent(apiInfo.getName(), apiInfo));
|
||||
APIInfo[] apiInfos = consumerRESTAPIServices.getAllApis(apiApplicationInfo, queryParams, headerParams);
|
||||
Arrays.stream(apiInfos).forEach(apiInfo -> uniqueApiSet.putIfAbsent(apiInfo.getName(), apiInfo));
|
||||
}
|
||||
}
|
||||
|
||||
List<APIInfo> uniqueApiList = new ArrayList<>(uniqueApiSet.values());
|
||||
|
||||
@ -135,7 +135,8 @@ public class KeyMgtServiceImpl implements KeyMgtService {
|
||||
//todo --> can use requestingUserAccessToken token here to get application data - modify getApplication
|
||||
// method signature
|
||||
|
||||
io.entgra.device.mgt.core.apimgt.extension.rest.api.bean.APIMConsumer.Application application = getApplication(clientName, owner);
|
||||
io.entgra.device.mgt.core.apimgt.extension.rest.api.bean.APIMConsumer.Application application =
|
||||
getApplication(clientName, requestingUserAccessToken);
|
||||
String applicationUUID = application.getApplicationId();
|
||||
|
||||
// do app key mapping
|
||||
|
||||
Loading…
Reference in New Issue
Block a user