Skip to content

Conversation

@simount3
Copy link
Collaborator

@simount3 simount3 commented Oct 14, 2025

제목(필수): [TYPE]: 제목 예) [FEAT]: 회원가입 기능 추가

제목 규칙 자세히 보기
  • 형식: [TYPE]: 제목
  • 제한: 50자 이내, 첫 글자 대문자, 명령문
  • TYPE: FEAT FIX REFACTOR COMMENT STYLE TEST CHORE INIT

무엇을 / 왜

  • 무엇(What):

    • ScenarioRepository.updateRepresentativeStatus 추가
    • UserInfoService의 createMyInfo/updateMyInfo -> saveOrUpdateMyInfo로 통합
    • getMyScenarios에서 빈 ID 리스트 시 SceneType 조회 스킵 (불필요 쿼리 제거)
    • 입력 정제: username, beliefs에 trim() 적용
  • 왜(Why):

    • 한 번의 업데이트로 대표 단일성 보장 및 트랜잭션 정합성 향상
    • 동일 로직 중복 제거로 코드 단순화/유지보수성 개선
    • 빈 결과 조회 방지로 DB 부하 경감

어떻게(요약) — 3줄 이내

  • 쿼리 한 방으로 대표 시나리오 true/false 동시 처리
  • saveOrUpdateMyInfo로 서비스 단일화
  • scenarioIds.isEmpty() 시 SceneType 조회 생략, toList()로 간결화

영향 범위

  • API 변경
  • DB 마이그레이션
  • Breaking Change
  • 보안/권한 영향
  • 문서/가이드 업데이트 필요

체크리스트

  • 타입 라벨 부착 (FEAT/FIX/REFACTOR/COMMENT/STYLE/TEST/CHORE/INIT)
  • 로컬/CI 테스트 통과
  • 영향도 점검 완료
  • 주석/문서 반영(필요 시)

ToDo (선택)

  • 할 일 1
  • 할 일 2

스크린샷/증빙(선택)

이슈 연결 (자동)

Closes #133

Copy link
Collaborator

@lcs9317 lcs9317 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

고생하셨습니다!

Copy link
Collaborator

@Gooraeng Gooraeng left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

확인했습니다!

Copy link
Collaborator

@johnbosco0414 johnbosco0414 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

고생하셨습니다!

@simount3 simount3 merged commit a73ff8c into main Oct 14, 2025
3 checks passed
@simount3 simount3 deleted the refactor branch October 14, 2025 08:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[REFACTOR]: users info service 코드 리팩토링

5 participants