Role stuff

This commit is contained in:
Anthony Stirling
2023-12-25 12:58:49 +00:00
parent 690720f4e3
commit dd9dd72f35
5 changed files with 41 additions and 3 deletions

View File

@@ -100,10 +100,12 @@ public class PipelineController {
@Autowired
ApplicationProperties applicationProperties;
@Autowired
@Autowired(required=false)
private UserServiceInterface userService;
private String getApiKeyForUser() {
if(userService == null)
return "";
return userService.getApiKeyForUser(Role.INTERNAL_API_USER.getRoleId());
}