Skip to content

Fix: 첨삭 상세 조회에 대한 INTERNAL 필터 처리 제거#388

Merged
hyoinkang merged 2 commits intodevfrom
fix/#387-get-correction-internal
May 1, 2026
Merged

Fix: 첨삭 상세 조회에 대한 INTERNAL 필터 처리 제거#388
hyoinkang merged 2 commits intodevfrom
fix/#387-get-correction-internal

Conversation

@hyoinkang
Copy link
Copy Markdown
Contributor

@hyoinkang hyoinkang commented Apr 30, 2026

Summary

첨삭 상세 조회에 대한 INTERNAL 필터 처리를 제거하여 외부 포트폴리오 첨삭 시 생길 수 있는 에러를 해결합니다.

Changes

  • GET /corrections/:correctionId API 내부 로직 수정

Type of Change

해당하는 항목에 체크해주세요:

  • Bug fix (기존 기능을 수정하는 변경)
  • New feature (새로운 기능 추가)
  • Breaking change (기존 기능에 영향을 주는 변경)
  • Refactoring (기능 변경 없이 코드 개선)
  • Documentation (문서 변경)
  • Chore (빌드, 설정 등)

Target Environment

배포 대상 브랜치를 선택해주세요:

  • Dev (dev)
  • Prod (main)

Related Issues

관련 이슈를 연결해주세요:

Testing

테스트 방법을 작성해주세요:

  • Postman/Swagger로 API 호출 확인
  • 단위 테스트 통과
  • E2E 테스트 통과

Checklist

PR 생성 전 확인사항:

  • 코드 컨벤션을 준수했습니다 (docs/development/CODE_STYLE.md)
  • Git 컨벤션을 준수했습니다 (docs/development/GIT_CONVENTIONS.md)
  • 네이밍 컨벤션을 준수했습니다 (docs/development/NAMING_CONVENTIONS.md)
  • 로컬에서 빌드가 성공합니다 (pnpm run build)
  • 로컬에서 린트가 통과합니다 (pnpm run lint)
  • (API 변경 시) Swagger 문서가 업데이트되었습니다
  • (필요 시) 테스트 코드를 작성했습니다

Screenshots (Optional)

UI 변경이 있다면 스크린샷을 첨부해주세요.

Additional Notes

리뷰어에게 전달할 추가 정보가 있다면 작성해주세요.

@hyoinkang hyoinkang self-assigned this Apr 30, 2026
@hyoinkang hyoinkang added the 🐛 fix Something isn't working label Apr 30, 2026
@gemini-code-assist
Copy link
Copy Markdown

Summary of Changes

Hello, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

본 PR은 첨삭 상세 조회 API에서 강제되던 INTERNAL 포트폴리오 필터링 로직을 제거하는 것을 목적으로 합니다. 이 변경을 통해 외부 포트폴리오 첨삭 시 발생하던 예외 상황을 방지하고, 불필요한 의존성을 제거하여 코드의 복잡도를 낮추었습니다.

Highlights

  • INTERNAL 필터 제거: 첨삭 상세 조회 시 수행되던 INTERNAL 포트폴리오 필터링 로직을 제거하여 외부 포트폴리오 첨삭 시 발생하는 에러를 해결했습니다.
  • 코드 간소화: InternalCorrectionFacade에서 불필요한 PortfolioService 의존성을 제거하고, 서비스 호출을 직접 반환하도록 리팩토링했습니다.

🧠 New Feature in Public Preview: You can now enable Memory to help Gemini Code Assist learn from your team's feedback. This makes future code reviews more consistent and personalized to your project's style. Click here to enable Memory in your admin console.

Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for GitHub and other Google products, sign up here.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

Copy link
Copy Markdown

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

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

Code Review

InternalCorrectionFacade에서 PortfolioService 의존성과 필터링 로직을 제거하고 PortfolioCorrectionService를 단순 호출하도록 변경하였습니다. 리뷰어는 이로 인해 Facade가 불필요한 추상화 계층이 되었음을 지적하며, Facade를 제거하거나 계층 구조를 명확히 할 것을 권고했습니다.

Comment thread src/modules/internal/application/facades/internal-correction.facade.ts Outdated
- 서비스 로직이 줄어듦에 따라 파사드 대신 서비스를 직접 호출하도록 리팩토링함
Copilot AI review requested due to automatic review settings May 1, 2026 00:01
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Removes the INTERNAL-only filtering logic from the internal “correction detail” read path so AI-server driven correction flows can fetch the full set of portfolios/items (including externally sourced portfolios) without being filtered out.

Changes:

  • Wire GET /corrections/:correctionId to call PortfolioCorrectionService.getInternalCorrectionDetail directly.
  • Remove InternalCorrectionFacade and its DI registration from InternalModule.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.

File Description
src/modules/internal/presentation/internal-correction.controller.ts Stops using the internal facade and directly fetches correction detail payload from PortfolioCorrectionService.
src/modules/internal/internal.module.ts Removes InternalCorrectionFacade from module providers/imports.
src/modules/internal/application/facades/internal-correction.facade.ts Deletes the facade that applied SourceType.INTERNAL filtering to portfolios/items in the internal correction detail response.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@hyoinkang hyoinkang merged commit bd75cbf into dev May 1, 2026
6 checks passed
@hyoinkang hyoinkang deleted the fix/#387-get-correction-internal branch May 1, 2026 00:03
hyoinkang added a commit that referenced this pull request May 1, 2026
* fix: 첨삭 상세 조회에 대한 INTERNAL 필터 처리 제거

* refactor: 불필요한 계층구조 제거

- 서비스 로직이 줄어듦에 따라 파사드 대신 서비스를 직접 호출하도록 리팩토링함
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

🐛 fix Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Fix] AI 서버 측에서 첨삭 생성 시 포트폴리오를 찾지 못하는 문제 원인 해결

2 participants