dev check null company
Test Workflow / test (push) Successful in 2s

This commit is contained in:
vladp
2026-01-29 21:46:37 +07:00
parent c539b1fbc2
commit fb5642db9e
4 changed files with 11 additions and 3 deletions
@@ -47,7 +47,7 @@ public class UserController {
@GetMapping("/all")
public ResponseEntity<List<UserDTO>> getAllUsers() {
List<UserDTO> allUsers = userRepository.findAll().stream()
.map(u -> new UserDTO(u.getFullName(), u.getCompany().getCompanyName(), u.getEmail(), u.isActive(),
.map(u -> new UserDTO(u.getFullName(), u.getCompanyName(), u.getEmail(), u.isActive(),
u.getPhone(), u.getGenderType(),
u.getBirthday(), u.getCreatedAt(), u.getSubscriptionType()))
.toList();