diff --git a/src/main/java/de/caritas/cob/userservice/api/adapters/web/mapping/AppointmentDtoMapper.java b/src/main/java/de/caritas/cob/userservice/api/adapters/web/mapping/AppointmentDtoMapper.java index 08a1ca8de..6d8df55a4 100644 --- a/src/main/java/de/caritas/cob/userservice/api/adapters/web/mapping/AppointmentDtoMapper.java +++ b/src/main/java/de/caritas/cob/userservice/api/adapters/web/mapping/AppointmentDtoMapper.java @@ -37,8 +37,8 @@ public Map mapOf(Appointment appointment, AuthenticatedUser auth appointmentMap.put("consultantId", authenticatedUser.getUserId()); } else if (authenticatedUser.getRoles().contains(UserRole.TECHNICAL.getValue()) && appointment.getConsultantEmail() != null) { - Optional consultant = consultantRepository - .findByEmailAndDeleteDateIsNull(appointment.getConsultantEmail()); + Optional consultant = + consultantRepository.findByEmailAndDeleteDateIsNull(appointment.getConsultantEmail()); if (!consultant.isPresent()) { throw new BadRequestException( "Consultant doesn't exist for give email " + appointment.getConsultantEmail());