Skip to content
Snippets Groups Projects
Commit dee73fc6 authored by OZGCloud's avatar OZGCloud
Browse files

OZG-7378 cleanup after review

parent e0c9c627
No related branches found
No related tags found
No related merge requests found
......@@ -22,6 +22,12 @@ public class UserService {
@Qualifier(ArchiveManagerConfiguration.USER_PROFILE_MAPPER_NAME) // NOSONAR
private final UserProfileMapper mapper;
public String getFullNameById(String userId) {
// TODO (Story offen) es soll der Name des Systems geliefert werden, wenn kein
// Mensch die Aktion ausgeführt hat
return getById(userId).map(UserProfile::getFullName).orElse("automatisch");
}
public Optional<UserProfile> getById(String userId) {
return Optional.of(userId).filter(id -> !id.startsWith(SYSTEM_USER_ID_PREFIX))
.map(OzgCloudUserId::from)
......@@ -29,10 +35,4 @@ public class UserService {
.map(mapper::fromOzgUserProfile);
}
public String getFullNameById(String userId) {
// TODO (Story offen) es soll der Name des Systems geliefert werden, wenn kein
// Mensch die Aktion ausgeführt hat
return getById(userId).map(UserProfile::getFullName).orElse("automatisch");
}
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment