Skip to content

Commit

Permalink
test remove post construct
Browse files Browse the repository at this point in the history
  • Loading branch information
gitCarrot committed Sep 7, 2024
1 parent 35bf348 commit d794700
Showing 1 changed file with 10 additions and 11 deletions.
21 changes: 10 additions & 11 deletions src/main/java/edu/hawaii/its/api/controller/OotbRestController.java
Original file line number Diff line number Diff line change
Expand Up @@ -42,23 +42,22 @@ public class OotbRestController {
public OotbRestController(UserContextService userContextService,
OotbStaticUserAuthenticationFilter ootbAuthenticationFilter,
OotbActiveUserProfileService ootbActiveUserProfileService,
OotbHttpRequestService ootbHttpRequestService,
Realm realmService) {
OotbHttpRequestService ootbHttpRequestService) {
this.userContextService = userContextService;
this.ootbAuthenticationFilter = ootbAuthenticationFilter;
this.ootbActiveUserProfileService = ootbActiveUserProfileService;
this.ootbHttpRequestService = ootbHttpRequestService;
}

@PostConstruct()
public void init() {
String adminProfile = ootbActiveUserProfileService.findGivenNameForAdminRole();
if (adminProfile != null) {
updateActiveDefaultUser(adminProfile);
} else {
logger.error("Admin profile not found, unable to initiate default API request.");
}
}
// @PostConstruct()
// public void init() {
// String adminProfile = ootbActiveUserProfileService.findGivenNameForAdminRole();
// if (adminProfile != null) {
// updateActiveDefaultUser(adminProfile);
// } else {
// logger.error("Admin profile not found, unable to initiate default API request.");
// }
// }

/*
* Checks to make sure that the API is running and that there are no issues with
Expand Down

0 comments on commit d794700

Please sign in to comment.