Merge pull request 'check if CouId is null' (#2) from develop into master
Reviewed-on: #2
This commit is contained in:
commit
aeca9ce38b
|
@ -142,7 +142,9 @@ public class AuthorizationServiceImpl implements AuthorizationService {
|
|||
int coPersonId = aaiRegistryService.getCoPersonIdByEmail(email);
|
||||
List<Integer> list = new ArrayList<>();
|
||||
for (JsonElement element : aaiRegistryService.getRolesWithStatus(coPersonId, AaiRegistryService.RoleStatus.ACTIVE)) {
|
||||
list.add(element.getAsJsonObject().get("CouId").getAsInt());
|
||||
if (element.getAsJsonObject().get("CouId") != null) {
|
||||
list.add(element.getAsJsonObject().get("CouId").getAsInt());
|
||||
}
|
||||
}
|
||||
return aaiRegistryService.getCouNames(list).values();
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue