Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
import org.springframework.transaction.annotation.Transactional;

import com.example.RealMatch.global.exception.CustomException;
import com.example.RealMatch.match.domain.repository.MatchCampaignHistoryRepository;
import com.example.RealMatch.user.application.util.NicknameValidator;
import com.example.RealMatch.user.domain.entity.AuthenticationMethod;
import com.example.RealMatch.user.domain.entity.User;
Expand Down Expand Up @@ -36,7 +35,6 @@
public class UserService {

private final UserRepository userRepository;
private final MatchCampaignHistoryRepository matchCampaignHistoryRepository;
private final ScrapMockDataProvider scrapMockDataProvider;
private final AuthenticationMethodRepository authenticationMethodRepository;
private final UserMatchingDetailRepository userMatchingDetailRepository;
Expand All @@ -48,8 +46,8 @@ public MyPageResponseDto getMyPage(Long userId) {
User user = userRepository.findById(userId)
.orElseThrow(() -> new CustomException(UserErrorCode.USER_NOT_FOUND));

// 매칭 검사 여부 확인 (캠페인 매칭 검사 기록 존재 여부)
boolean hasMatchingTest = matchCampaignHistoryRepository.existsByUserId(userId);
// 매칭 검사 여부 확인
boolean hasMatchingTest = userMatchingDetailRepository.existsByUserIdAndIsDeprecatedFalse(userId);

// DTO 변환 및 반환
return MyPageResponseDto.from(user, hasMatchingTest);
Expand Down
Loading