Revision 57326
Added by Michele Artini over 4 years ago
OrganizationController.java | ||
---|---|---|
130 | 130 |
@RequestMapping(value = "/similarities", method = RequestMethod.POST) |
131 | 131 |
public List<OpenaireSimRel> saveSimilarities(@RequestBody final List<OpenaireSimRel> simrels, final Authentication authentication) { |
132 | 132 |
|
133 |
final boolean b = simrels.stream() |
|
133 |
final boolean b = User.isSuperUser(authentication) || simrels.stream()
|
|
134 | 134 |
.map(OpenaireSimRel::getLocalId) |
135 | 135 |
.distinct() |
136 | 136 |
.allMatch(id -> organizationRepository.verifyAuthorizationForId(id, authentication.getName())); |
Also available in: Unified diff
ui