diff --git a/src/main/java/com/gongjakso/server/domain/apply/repository/ApplyRepository.java b/src/main/java/com/gongjakso/server/domain/apply/repository/ApplyRepository.java index ed53a30..11e4176 100644 --- a/src/main/java/com/gongjakso/server/domain/apply/repository/ApplyRepository.java +++ b/src/main/java/com/gongjakso/server/domain/apply/repository/ApplyRepository.java @@ -8,5 +8,5 @@ public interface ApplyRepository extends JpaRepository, ApplyRepositoryCustom { Boolean existsByMemberIdAndTeamIdAndDeletedAtIsNull(Long memberId, Long teamId); Optional findByIdAndDeletedAtIsNull(Long applyId); - Optional findByTeamId(Long teamId); + Optional findByTeamIdAndDeletedAtIsNull(Long teamId); } diff --git a/src/main/java/com/gongjakso/server/domain/team/service/TeamService.java b/src/main/java/com/gongjakso/server/domain/team/service/TeamService.java index 4fdf6f2..d2a13eb 100644 --- a/src/main/java/com/gongjakso/server/domain/team/service/TeamService.java +++ b/src/main/java/com/gongjakso/server/domain/team/service/TeamService.java @@ -166,7 +166,7 @@ public TeamRes getTeam(Member member, Long contestId, Long teamId) { throw new ApplicationException(ErrorCode.TEAM_NOT_FOUND_EXCEPTION); } - List appliers = applyRepository.findByTeamId(teamId).stream() + List appliers = applyRepository.findByTeamIdAndDeletedAtIsNull(teamId).stream() .map(Apply::getMember) .toList();