Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. Weโ€™ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

๐Ÿ„ :: (Meogo-38) question crud #39

Merged
merged 8 commits into from
Sep 25, 2024
Merged

๐Ÿ„ :: (Meogo-38) question crud #39

merged 8 commits into from
Sep 25, 2024

Conversation

meltapplee
Copy link
Member

@meltapplee meltapplee commented Sep 25, 2024

close #38
แ„Œแ…ตแ†ฏแ„†แ…ฎแ†ซ แ„‰แ…กแ†จแ„Œแ…ฆ
แ„Œแ…ตแ†ฏแ„†แ…ฎแ†ซ แ„‰แ…ขแ†ผแ„‰แ…ฅแ†ผ
แ„Œแ…ตแ†ฏแ„†แ…ฎแ†ซ แ„’แ…กแ†จแ„€แ…ญแ„‡แ…งแ†ฏ แ„Œแ…ฉแ„’แ…ฌ
แ„Œแ…ตแ†ฏแ„†แ…ฎแ†ซแ„‰แ…ฎแ„Œแ…กใ…“ใ…‡

Summary by CodeRabbit

  • New Features

    • ๋Œ“๊ธ€ ์‚ญ์ œ ๊ธฐ๋Šฅ์ด /delete ์—”๋“œํฌ์ธํŠธ๋ฅผ ํ†ตํ•ด ์ œ๊ณต๋ฉ๋‹ˆ๋‹ค.
    • ์งˆ๋ฌธ ์ƒ์„ฑ, ์ˆ˜์ •, ์กฐํšŒ ๋ฐ ์‚ญ์ œ ๊ธฐ๋Šฅ์„ ์ง€์›ํ•˜๋Š” ์ƒˆ๋กœ์šด ์งˆ๋ฌธ ๊ด€๋ฆฌ API๊ฐ€ ์ถ”๊ฐ€๋˜์—ˆ์Šต๋‹ˆ๋‹ค.
    • ์งˆ๋ฌธ ์š”์ฒญ ๋ฐ ์ˆ˜์ • ์š”์ฒญ์„ ์œ„ํ•œ ๋ฐ์ดํ„ฐ ๊ตฌ์กฐ๊ฐ€ ๋„์ž…๋˜์—ˆ์Šต๋‹ˆ๋‹ค.
    • ํ•™๊ต ID์— ๋”ฐ๋ผ ์งˆ๋ฌธ์„ ์กฐํšŒํ•  ์ˆ˜ ์žˆ๋Š” ๊ธฐ๋Šฅ์ด ์ถ”๊ฐ€๋˜์—ˆ์Šต๋‹ˆ๋‹ค.
    • ์งˆ๋ฌธ ์œ ํ˜•์„ ์ •์˜ํ•˜๋Š” ์ƒˆ๋กœ์šด ์—ด๊ฑฐํ˜•์ด ๋„์ž…๋˜์—ˆ์Šต๋‹ˆ๋‹ค.
    • ๋ฆฌ๋ทฐ ์‚ฌ์ง„ ์‘๋‹ต ๊ตฌ์กฐ์— ์—ฐ๋„ ์ •๋ณด๊ฐ€ ์ถ”๊ฐ€๋˜์—ˆ์Šต๋‹ˆ๋‹ค.
  • Bug Fixes

    • ์งˆ๋ฌธ ์‚ญ์ œ ์‹œ ์‚ฌ์šฉ์ž ์†Œ์œ  ํ™•์ธ ๋กœ์ง์ด ์ถ”๊ฐ€๋˜์–ด ๋ณด์•ˆ์ด ๊ฐ•ํ™”๋˜์—ˆ์Šต๋‹ˆ๋‹ค.

@meltapplee meltapplee self-assigned this Sep 25, 2024
Copy link

coderabbitai bot commented Sep 25, 2024

Warning

Rate limit exceeded

@meltapplee has exceeded the limit for the number of commits or files that can be reviewed per hour. Please wait 14 minutes and 33 seconds before requesting another review.

โŒ› How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

๐Ÿšฆ How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

๐Ÿ“ฅ Commits

Files that changed from the base of the PR and between c50853e and 053a5f0.

Walkthrough

์ด๋ฒˆ ๋ณ€๊ฒฝ ์‚ฌํ•ญ์€ CommentController, Question, QuestionRepository, QuestionController, ๊ทธ๋ฆฌ๊ณ  ์—ฌ๋Ÿฌ ์„œ๋น„์Šค ํด๋ž˜์Šค์˜ ์ˆ˜์ • ๋ฐ ์ถ”๊ฐ€๋ฅผ ํฌํ•จํ•ฉ๋‹ˆ๋‹ค. CommentController์˜ DELETE ๋งคํ•‘์ด ๊ตฌ์ฒด์ ์ธ ๊ฒฝ๋กœ๋กœ ๋ณ€๊ฒฝ๋˜์—ˆ๊ณ , Question ํด๋ž˜์Šค์—๋Š” ์ƒˆ๋กœ์šด ์†์„ฑ๊ณผ ๋ฉ”์„œ๋“œ๊ฐ€ ์ถ”๊ฐ€๋˜์—ˆ์Šต๋‹ˆ๋‹ค. ๋˜ํ•œ, ์งˆ๋ฌธ ๊ด€๋ฆฌ์™€ ๊ด€๋ จ๋œ ์—ฌ๋Ÿฌ ์„œ๋น„์Šค์™€ DTO๊ฐ€ ๋„์ž…๋˜์–ด ์งˆ๋ฌธ ์ƒ์„ฑ, ์ˆ˜์ •, ์‚ญ์ œ ๋ฐ ์กฐํšŒ ๊ธฐ๋Šฅ์ด ๊ฐ•ํ™”๋˜์—ˆ์Šต๋‹ˆ๋‹ค.

Changes

ํŒŒ์ผ ๊ฒฝ๋กœ ๋ณ€๊ฒฝ ์š”์•ฝ
src/main/kotlin/org/meogo/domain/comment/presentation/CommentController.kt DELETE ๋งคํ•‘์ด /delete๋กœ ๋ณ€๊ฒฝ๋˜์—ˆ์œผ๋ฉฐ, delete ๋ฉ”์„œ๋“œ๋Š” comment_id๋ฅผ ์š”์ฒญ ๋งค๊ฐœ๋ณ€์ˆ˜๋กœ ์œ ์ง€.
src/main/kotlin/org/meogo/domain/question/domain/Question.kt schoolId ๋ฐ questionType ์†์„ฑ์ด ์ถ”๊ฐ€๋˜์—ˆ๊ณ , modify ๋ฐ format ๋ฉ”์„œ๋“œ๊ฐ€ ์ถ”๊ฐ€๋จ.
src/main/kotlin/org/meogo/domain/question/domain/QuestionRepository.kt save, findBySchoolId, deleteById ๋ฉ”์„œ๋“œ๊ฐ€ ์ถ”๊ฐ€๋˜์–ด ์งˆ๋ฌธ ๊ด€๋ฆฌ ๊ธฐ๋Šฅ์ด ํ–ฅ์ƒ๋จ.
src/main/kotlin/org/meogo/domain/question/enum/QuestionType.kt QuestionType ์—ด๊ฑฐํ˜• ํด๋ž˜์Šค๊ฐ€ ์ถ”๊ฐ€๋˜์–ด ์งˆ๋ฌธ ์œ ํ˜•์„ ์ •์˜.
src/main/kotlin/org/meogo/domain/question/presentation/QuestionController.kt ์งˆ๋ฌธ ์ƒ์„ฑ, ์ˆ˜์ •, ์กฐํšŒ ๋ฐ ์‚ญ์ œ๋ฅผ ์œ„ํ•œ ์—ฌ๋Ÿฌ ๋ฉ”์„œ๋“œ๊ฐ€ ์ถ”๊ฐ€๋จ.
src/main/kotlin/org/meogo/domain/question/presentation/dto/request/ModifyQuestionRequest.kt ์งˆ๋ฌธ ์ˆ˜์ •์„ ์œ„ํ•œ ๋ฐ์ดํ„ฐ ํด๋ž˜์Šค๊ฐ€ ์ถ”๊ฐ€๋˜์—ˆ์œผ๋ฉฐ, content ๋ฐ questionType ์†์„ฑ์„ ํฌํ•จ.
src/main/kotlin/org/meogo/domain/question/presentation/dto/request/QuestionRequest.kt ์งˆ๋ฌธ ์š”์ฒญ์„ ์œ„ํ•œ ๋ฐ์ดํ„ฐ ํด๋ž˜์Šค๊ฐ€ ์ถ”๊ฐ€๋˜์—ˆ์œผ๋ฉฐ, schoolId, content, questionType ์†์„ฑ์„ ํฌํ•จ.
src/main/kotlin/org/meogo/domain/question/presentation/dto/response/QuerySchoolQuestionResponse.kt ์งˆ๋ฌธ ์กฐํšŒ ์‘๋‹ต์„ ์œ„ํ•œ ๋ฐ์ดํ„ฐ ํด๋ž˜์Šค๊ฐ€ ์ถ”๊ฐ€๋จ.
src/main/kotlin/org/meogo/domain/question/service/CreateQuestionService.kt ์งˆ๋ฌธ ์ƒ์„ฑ์„ ์œ„ํ•œ ์„œ๋น„์Šค ํด๋ž˜์Šค๊ฐ€ ์ถ”๊ฐ€๋˜์—ˆ์œผ๋ฉฐ, execute ๋ฉ”์„œ๋“œ๊ฐ€ ํฌํ•จ๋จ.
src/main/kotlin/org/meogo/domain/question/service/DeleteQuestionService.kt ์งˆ๋ฌธ ์‚ญ์ œ๋ฅผ ์œ„ํ•œ ์„œ๋น„์Šค ํด๋ž˜์Šค๊ฐ€ ์ถ”๊ฐ€๋˜์—ˆ์œผ๋ฉฐ, execute ๋ฉ”์„œ๋“œ๊ฐ€ ํฌํ•จ๋จ.
src/main/kotlin/org/meogo/domain/question/service/ModifyQuestionService.kt ์งˆ๋ฌธ ์ˆ˜์ •์„ ์œ„ํ•œ ์„œ๋น„์Šค ํด๋ž˜์Šค๊ฐ€ ์ถ”๊ฐ€๋˜์—ˆ์œผ๋ฉฐ, execute ๋ฉ”์„œ๋“œ๊ฐ€ ํฌํ•จ๋จ.
src/main/kotlin/org/meogo/domain/question/service/QuerySchoolQuestionService.kt ํ•™๊ต ์งˆ๋ฌธ ์กฐํšŒ๋ฅผ ์œ„ํ•œ ์„œ๋น„์Šค ํด๋ž˜์Šค๊ฐ€ ์ถ”๊ฐ€๋˜์—ˆ์œผ๋ฉฐ, execute ๋ฉ”์„œ๋“œ๊ฐ€ ํฌํ•จ๋จ.
src/main/kotlin/org/meogo/domain/review/presentation/dto/response/ReviewPictureResponse.kt year ์†์„ฑ์ด ์ถ”๊ฐ€๋˜์–ด ์‘๋‹ต ๋ฐ์ดํ„ฐ ๊ตฌ์กฐ๊ฐ€ ๊ฐœ์„ ๋จ.
src/main/kotlin/org/meogo/domain/review/service/QueryReviewPictureService.kt year ๋ณ€์ˆ˜๋ฅผ ์ถ”๊ฐ€ํ•˜์—ฌ ๋ฆฌ๋ทฐ ์‚ฌ์ง„ ์‘๋‹ต์„ ๊ฐœ์„ ํ•จ.

Possibly related PRs

  • ๐Ÿ„ :: (Meogo-9) create reviewย #10: ReviewController ํด๋ž˜์Šค์— ๋ฆฌ๋ทฐ ์ƒ์„ฑ์„ ์œ„ํ•œ ์ƒˆ๋กœ์šด ๋ฉ”์„œ๋“œ๊ฐ€ ์ถ”๊ฐ€๋˜์–ด CommentController์˜ ๋ณ€๊ฒฝ ์‚ฌํ•ญ๊ณผ ๊ด€๋ จ๋จ.
  • ๐Ÿ„ :: (Meogo-16) delete reviewย #17: ๋ฆฌ๋ทฐ ์‚ญ์ œ๋ฅผ ์œ„ํ•œ ์ƒˆ๋กœ์šด ์—”๋“œํฌ์ธํŠธ๊ฐ€ ReviewController์— ์ถ”๊ฐ€๋˜์–ด CommentController์˜ ๋ณ€๊ฒฝ ์‚ฌํ•ญ๊ณผ ์ง์ ‘์ ์œผ๋กœ ๊ด€๋ จ๋จ.
  • ๐Ÿ„ :: (Meogo-32) modify community postย #33: Post ํด๋ž˜์Šค๊ฐ€ ๋ณ€๊ฒฝ๋˜์–ด ์†์„ฑ์„ ์ˆ˜์ • ๊ฐ€๋Šฅํ•˜๊ฒŒ ํ•˜๊ณ  ์—…๋ฐ์ดํŠธ ๋ฉ”์„œ๋“œ๋ฅผ ๋„์ž…ํ•˜์—ฌ CommentController์˜ ๋ณ€๊ฒฝ ์‚ฌํ•ญ๊ณผ ์—ฐ๊ด€๋จ.
  • ๐Ÿ„ :: (Meogo-36) detault imageย #37: PostRepository๊ฐ€ ์‚ฌ์šฉ์ž ID๋กœ ๊ฒŒ์‹œ๋ฌผ์„ ๊ฒ€์ƒ‰ํ•˜๋Š” ๋ฉ”์„œ๋“œ๋ฅผ ์ถ”๊ฐ€ํ•˜์—ฌ CommentController์˜ ๋ณ€๊ฒฝ ์‚ฌํ•ญ๊ณผ ๊ด€๋ จ๋จ.

Suggested labels

core

Poem

๐Ÿฐ ์ƒˆ๋กœ์šด ์งˆ๋ฌธ์ด ํƒœ์–ด๋‚˜๊ณ ,
์‚ญ์ œ๋œ ๋Œ“๊ธ€์€ ์‚ฌ๋ผ์ง€๋„ค,
ํ•™๊ต์˜ ์งˆ๋ฌธ๋“ค ๋ชจ์—ฌ,
์„œ๋น„์Šค๊ฐ€ ํ•จ๊ป˜ ์ถค์ถ”๋„ค.
์ฝ”๋“œ ์†์— ์ˆจ์€ ์ด์•ผ๊ธฐ,
์šฐ๋ฆฌ ํ•จ๊ป˜ ๋‚˜๋ˆ„๋ฆฌ๋ผ! ๐ŸŽ‰


Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?

โค๏ธ Share
๐Ÿชง Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Generate unit testing code for this file.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai generate unit testing code for this file.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and generate unit testing code.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 10

๐Ÿงน Outside diff range and nitpick comments (14)
src/main/kotlin/org/meogo/domain/question/enum/QuestionType.kt (1)

1-5: ์ „๋ฐ˜์ ์ธ ๊ตฌ์กฐ์™€ ๋ช…๋ช… ๊ทœ์น™์ด ์ ์ ˆํ•ฉ๋‹ˆ๋‹ค.

enum ํด๋ž˜์Šค์˜ ๊ตฌ์กฐ์™€ ๋ช…๋ช… ๊ทœ์น™์ด Kotlin ํ‘œ์ค€์„ ์ž˜ ๋”ฐ๋ฅด๊ณ  ์žˆ์Šต๋‹ˆ๋‹ค. ํ•˜์ง€๋งŒ ๋ช‡ ๊ฐ€์ง€ ๊ฐœ์„  ์‚ฌํ•ญ์„ ์ œ์•ˆ๋“œ๋ฆฝ๋‹ˆ๋‹ค:

  1. enum ํด๋ž˜์Šค์™€ ๊ฐ ์ƒ์ˆ˜์— ๋Œ€ํ•œ KDoc ์ฃผ์„์„ ์ถ”๊ฐ€ํ•˜์—ฌ ๋ชฉ์ ๊ณผ ์‚ฌ์šฉ ์‚ฌ๋ก€๋ฅผ ๋ช…ํ™•ํžˆ ์„ค๋ช…ํ•ด์ฃผ์„ธ์š”.
  2. 'ETC' ์ƒ์ˆ˜๋Š” ๋„ˆ๋ฌด ๋ชจํ˜ธํ•  ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค. ๋” ๊ตฌ์ฒด์ ์ธ ์นดํ…Œ๊ณ ๋ฆฌ๋กœ ๋Œ€์ฒดํ•˜๊ฑฐ๋‚˜, ๋ฐ˜๋“œ์‹œ ํ•„์š”ํ•œ ๊ฒฝ์šฐ 'OTHER'๋กœ ์ด๋ฆ„์„ ๋ณ€๊ฒฝํ•˜๋Š” ๊ฒƒ์„ ๊ณ ๋ คํ•ด๋ณด์„ธ์š”.

๋‹ค์Œ๊ณผ ๊ฐ™์ด KDoc ์ฃผ์„์„ ์ถ”๊ฐ€ํ•˜๊ณ  'ETC'๋ฅผ 'OTHER'๋กœ ๋ณ€๊ฒฝํ•˜๋Š” ๊ฒƒ์„ ์ œ์•ˆํ•ฉ๋‹ˆ๋‹ค:

 package org.meogo.domain.question.enum

+/**
+ * ์งˆ๋ฌธ์˜ ์œ ํ˜•์„ ๋‚˜ํƒ€๋‚ด๋Š” ์—ด๊ฑฐํ˜• ํด๋ž˜์Šค์ž…๋‹ˆ๋‹ค.
+ * ์ด ์—ด๊ฑฐํ˜•์€ ์‹œ์Šคํ…œ ๋‚ด์˜ ๋‹ค์–‘ํ•œ ์งˆ๋ฌธ ์นดํ…Œ๊ณ ๋ฆฌ๋ฅผ ์ •์˜ํ•ฉ๋‹ˆ๋‹ค.
+ */
 enum class QuestionType {
-    LIFE, ENTRANCE, FACILITIES, ETC
+    /** ์ผ์ƒ ์ƒํ™œ๊ณผ ๊ด€๋ จ๋œ ์งˆ๋ฌธ */
+    LIFE,
+    /** ์ž…ํ•™ ๋˜๋Š” ์ž…์ฃผ์™€ ๊ด€๋ จ๋œ ์งˆ๋ฌธ */
+    ENTRANCE,
+    /** ์‹œ์„ค ์ด์šฉ์— ๊ด€ํ•œ ์งˆ๋ฌธ */
+    FACILITIES,
+    /** ๋‹ค๋ฅธ ์นดํ…Œ๊ณ ๋ฆฌ์— ์†ํ•˜์ง€ ์•Š๋Š” ๊ธฐํƒ€ ์งˆ๋ฌธ */
+    OTHER
 }
src/main/kotlin/org/meogo/domain/review/presentation/dto/response/ReviewPictureResponse.kt (1)

1-6: ๋ณ€๊ฒฝ ์‚ฌํ•ญ์ด ์ ์ ˆํ•ด ๋ณด์ž…๋‹ˆ๋‹ค.

year ์†์„ฑ์„ ์ถ”๊ฐ€ํ•œ ๊ฒƒ์€ ์ข‹์€ ๋ณ€๊ฒฝ์‚ฌํ•ญ์œผ๋กœ ๋ณด์ž…๋‹ˆ๋‹ค. ์ด๋Š” ๋ฆฌ๋ทฐ ์‚ฌ์ง„์˜ ์—ฐ๋„ ์ •๋ณด๋ฅผ ์ œ๊ณตํ•˜์—ฌ ๋ฐ์ดํ„ฐ์˜ ์‹œ๊ฐ„์  ๋งฅ๋ฝ์„ ์ถ”๊ฐ€ํ•  ๊ฒƒ์ž…๋‹ˆ๋‹ค.

year ์†์„ฑ์˜ ๋ชฉ์ ์„ ๋ช…ํ™•ํžˆ ํ•˜๊ธฐ ์œ„ํ•ด ๊ฐ„๋‹จํ•œ ์ฃผ์„์„ ์ถ”๊ฐ€ํ•˜๋Š” ๊ฒƒ์ด ์ข‹๊ฒ ์Šต๋‹ˆ๋‹ค. ์˜ˆ๋ฅผ ๋“ค์–ด:

data class ReviewPictureResponse(
    /** ๋ฆฌ๋ทฐ ์‚ฌ์ง„์ด ์ดฌ์˜๋œ ์—ฐ๋„ */
    val year: Int,
    val image: String
)

์ด๋ ‡๊ฒŒ ํ•˜๋ฉด ์ด ์†์„ฑ์˜ ์˜๋„๊ฐ€ ๋” ๋ช…ํ™•ํ•ด์งˆ ๊ฒƒ์ž…๋‹ˆ๋‹ค.

src/main/kotlin/org/meogo/domain/question/presentation/dto/request/ModifyQuestionRequest.kt (1)

7-10: ์†์„ฑ ์„ ์–ธ์ด ์ ์ ˆํ•˜๋ฉฐ, ๊ฐœ์„  ๊ฐ€๋Šฅ์„ฑ์ด ์žˆ์Šต๋‹ˆ๋‹ค.

content ์†์„ฑ์— ๋Œ€ํ•œ ํฌ๊ธฐ ์ œ์•ฝ ์กฐ๊ฑด์€ ์งˆ๋ฌธ ๋‚ด์šฉ์ด ๋น„์–ด์žˆ์ง€ ์•Š๊ณ  ๋„ˆ๋ฌด ๊ธธ์ง€ ์•Š๋„๋ก ๋ณด์žฅํ•ฉ๋‹ˆ๋‹ค. questionType ์†์„ฑ์— QuestionType enum์„ ์‚ฌ์šฉํ•œ ๊ฒƒ์€ ํƒ€์ž… ์•ˆ์ „์„ฑ์„ ์œ„ํ•ด ์ข‹์Šต๋‹ˆ๋‹ค.

๋‹ค๋งŒ, questionType ์†์„ฑ์— ๋Œ€ํ•œ ์œ ํšจ์„ฑ ๊ฒ€์‚ฌ๋‚˜ ์ œ์•ฝ ์กฐ๊ฑด์ด ์—†์Šต๋‹ˆ๋‹ค. ํ•„์š”ํ•˜๋‹ค๋ฉด @field:Valid ์–ด๋…ธํ…Œ์ด์…˜์„ ์ถ”๊ฐ€ํ•˜์—ฌ QuestionType์˜ ์œ ํšจ์„ฑ์„ ๊ฒ€์‚ฌํ•  ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค. ์˜ˆ๋ฅผ ๋“ค์–ด:

@field:Valid
val questionType: QuestionType

์ด๋ ‡๊ฒŒ ํ•˜๋ฉด QuestionType์— ์ •์˜๋œ ๋ชจ๋“  ์œ ํšจ์„ฑ ๊ฒ€์‚ฌ ๊ทœ์น™์ด ์ ์šฉ๋ฉ๋‹ˆ๋‹ค.

src/main/kotlin/org/meogo/domain/question/presentation/dto/request/QuestionRequest.kt (1)

7-7: schoolId์— ๋Œ€ํ•œ ์œ ํšจ์„ฑ ๊ฒ€์‚ฌ ์ถ”๊ฐ€ ๊ณ ๋ ค

schoolId ํ•„๋“œ์— ๋Œ€ํ•ด ์–‘์ˆ˜ ๊ฐ’๋งŒ ํ—ˆ์šฉํ•˜๋„๋ก ์œ ํšจ์„ฑ ๊ฒ€์‚ฌ๋ฅผ ์ถ”๊ฐ€ํ•˜๋Š” ๊ฒƒ์ด ์ข‹์„ ๊ฒƒ ๊ฐ™์Šต๋‹ˆ๋‹ค. ์˜ˆ๋ฅผ ๋“ค์–ด, @field:Positive ์–ด๋…ธํ…Œ์ด์…˜์„ ์‚ฌ์šฉํ•  ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.

-    val schoolId: Int,
+    @field:Positive
+    val schoolId: Int,
src/main/kotlin/org/meogo/domain/question/service/DeleteQuestionService.kt (2)

11-15: ํด๋ž˜์Šค ์„ ์–ธ๊ณผ ์ƒ์„ฑ์ž๊ฐ€ ์ž˜ ๊ตฌํ˜„๋˜์—ˆ์Šต๋‹ˆ๋‹ค.

@Service ์–ด๋…ธํ…Œ์ด์…˜์ด ์˜ฌ๋ฐ”๋ฅด๊ฒŒ ์‚ฌ์šฉ๋˜์—ˆ๊ณ , ์˜์กด์„ฑ ์ฃผ์ž…์ด ์ ์ ˆํžˆ ๊ตฌํ˜„๋˜์—ˆ์Šต๋‹ˆ๋‹ค.

๋‹ค์Œ๊ณผ ๊ฐ™์ด ์ƒ์„ฑ์ž์— @Autowired ์–ด๋…ธํ…Œ์ด์…˜์„ ์ถ”๊ฐ€ํ•˜๋Š” ๊ฒƒ์ด ์ข‹์Šต๋‹ˆ๋‹ค:

 @Service
+@Autowired
 class DeleteQuestionService(
     private val questionRepository: QuestionRepository,
     private val userFacade: UserFacade
 ) {

์ด๋Š” ๋ช…์‹œ์ ์œผ๋กœ ์˜์กด์„ฑ ์ฃผ์ž…์„ ๋‚˜ํƒ€๋‚ด๋ฉฐ, ์ฝ”๋“œ์˜ ๊ฐ€๋…์„ฑ์„ ํ–ฅ์ƒ์‹œํ‚ต๋‹ˆ๋‹ค.


17-25: execute ๋ฉ”์„œ๋“œ ๊ตฌํ˜„์ด ์ „๋ฐ˜์ ์œผ๋กœ ์ž˜ ๋˜์—ˆ์Šต๋‹ˆ๋‹ค.

ํŠธ๋žœ์žญ์…˜ ์ฒ˜๋ฆฌ, ์‚ฌ์šฉ์ž ํ™•์ธ, ์งˆ๋ฌธ ์†Œ์œ ๊ถŒ ๊ฒ€์ฆ ๋“ฑ์ด ๋…ผ๋ฆฌ์ ์œผ๋กœ ์ž˜ ๊ตฌํ˜„๋˜์–ด ์žˆ์Šต๋‹ˆ๋‹ค.

๋‹ค์Œ๊ณผ ๊ฐ™์€ ๊ฐœ์„ ์‚ฌํ•ญ์„ ๊ณ ๋ คํ•ด๋ณด์„ธ์š”:

  1. ์˜ˆ์™ธ ์ฒ˜๋ฆฌ๋ฅผ ๋” ๊ตฌ์ฒด์ ์œผ๋กœ ํ•  ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค. ์˜ˆ๋ฅผ ๋“ค์–ด:
val user = userFacade.currentUser() ?: throw UserNotFoundException("ํ˜„์žฌ ์‚ฌ์šฉ์ž๋ฅผ ์ฐพ์„ ์ˆ˜ ์—†์Šต๋‹ˆ๋‹ค.")
val question = questionRepository.findById(questionId) ?: throw QuestionNotFoundException("ID๊ฐ€ $questionId์ธ ์งˆ๋ฌธ์„ ์ฐพ์„ ์ˆ˜ ์—†์Šต๋‹ˆ๋‹ค.")
  1. ์‚ฌ์šฉ์ž ์ผ์น˜ ์—ฌ๋ถ€ ํ™•์ธ ๋กœ์ง์„ ๋ณ„๋„์˜ ๋ฉ”์„œ๋“œ๋กœ ์ถ”์ถœํ•˜์—ฌ ๊ฐ€๋…์„ฑ์„ ๋†’์ผ ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค:
private fun verifyQuestionOwnership(user: User, question: Question) {
    if (user != question.user) throw UserMisMatchException("์งˆ๋ฌธ์˜ ์†Œ์œ ์ž๊ฐ€ ์•„๋‹™๋‹ˆ๋‹ค.")
}
  1. ์‚ญ์ œ ์„ฑ๊ณต ์—ฌ๋ถ€๋ฅผ ๋ฐ˜ํ™˜ํ•˜๋Š” ๊ฒƒ์„ ๊ณ ๋ คํ•ด๋ณด์„ธ์š”. ์˜ˆ:
return questionRepository.deleteById(question.id) > 0

์ด๋Ÿฌํ•œ ๋ณ€๊ฒฝ์‚ฌํ•ญ๋“ค์€ ์ฝ”๋“œ์˜ ๊ฐ€๋…์„ฑ๊ณผ ์œ ์ง€๋ณด์ˆ˜์„ฑ์„ ํ–ฅ์ƒ์‹œํ‚ฌ ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.

src/main/kotlin/org/meogo/domain/question/service/CreateQuestionService.kt (1)

12-16: ํด๋ž˜์Šค ์„ ์–ธ๊ณผ ์ƒ์„ฑ์ž๊ฐ€ ์ž˜ ๊ตฌํ˜„๋˜์—ˆ์Šต๋‹ˆ๋‹ค.

@Service ์–ด๋…ธํ…Œ์ด์…˜๊ณผ ์˜์กด์„ฑ ์ฃผ์ž…์ด ์˜ฌ๋ฐ”๋ฅด๊ฒŒ ์‚ฌ์šฉ๋˜์—ˆ์Šต๋‹ˆ๋‹ค. ์ฝ”๋“œ์˜ ๊ฐ€๋…์„ฑ๊ณผ ์œ ์ง€๋ณด์ˆ˜์„ฑ์„ ๋†’์ด๊ธฐ ์œ„ํ•ด ๋‹ค์Œ๊ณผ ๊ฐ™์€ ์ž‘์€ ๊ฐœ์„ ์„ ์ œ์•ˆํ•ฉ๋‹ˆ๋‹ค:

์ƒ์„ฑ์ž ๋งค๊ฐœ๋ณ€์ˆ˜์— private val ๋Œ€์‹  private final์„ ์‚ฌ์šฉํ•˜๋Š” ๊ฒƒ์ด ์ข‹์Šต๋‹ˆ๋‹ค. ์ด๋ ‡๊ฒŒ ํ•˜๋ฉด ๋ถˆ๋ณ€์„ฑ์„ ๋ช…์‹œ์ ์œผ๋กœ ๋‚˜ํƒ€๋‚ผ ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค:

class CreateQuestionService(
    private final val questionRepository: QuestionRepository,
    private final val userFacade: UserFacade
)
src/main/kotlin/org/meogo/domain/question/service/ModifyQuestionService.kt (2)

12-16: ํด๋ž˜์Šค ์„ ์–ธ๊ณผ ์˜์กด์„ฑ ์ฃผ์ž…์ด ์ž˜ ๊ตฌํ˜„๋˜์—ˆ์Šต๋‹ˆ๋‹ค.

@Service ์–ด๋…ธํ…Œ์ด์…˜์„ ์‚ฌ์šฉํ•˜์—ฌ Spring ์„œ๋น„์Šค ํด๋ž˜์Šค๋กœ ์˜ฌ๋ฐ”๋ฅด๊ฒŒ ์„ ์–ธ๋˜์—ˆ์Šต๋‹ˆ๋‹ค. ์ƒ์„ฑ์ž๋ฅผ ํ†ตํ•œ ์˜์กด์„ฑ ์ฃผ์ž…์€ ์ข‹์€ ๋ฐฉ์‹์ž…๋‹ˆ๋‹ค.

๋‹ค์Œ๊ณผ ๊ฐ™์ด private val ํ‚ค์›Œ๋“œ๋ฅผ ์ƒ์„ฑ์ž ๋งค๊ฐœ๋ณ€์ˆ˜์— ์ง์ ‘ ์ถ”๊ฐ€ํ•˜์—ฌ ์ฝ”๋“œ๋ฅผ ๋” ๊ฐ„๊ฒฐํ•˜๊ฒŒ ๋งŒ๋“ค ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค:

 @Service
 class ModifyQuestionService(
-    private val questionRepository: QuestionRepository,
-    private val userFacade: UserFacade
+    private val questionRepository: QuestionRepository,
+    private val userFacade: UserFacade
 ) {

์ด๋ ‡๊ฒŒ ํ•˜๋ฉด ํด๋ž˜์Šค ๋ณธ๋ฌธ์—์„œ ๋ณ„๋„์˜ ํ”„๋กœํผํ‹ฐ ์„ ์–ธ์ด ํ•„์š” ์—†์–ด์ง‘๋‹ˆ๋‹ค.


18-28: execute ๋ฉ”์„œ๋“œ๊ฐ€ ์ž˜ ๊ตฌํ˜„๋˜์—ˆ์Šต๋‹ˆ๋‹ค.

ํŠธ๋žœ์žญ์…˜ ์ฒ˜๋ฆฌ, ์‚ฌ์šฉ์ž ํ™•์ธ, ์งˆ๋ฌธ ์กฐํšŒ, ์‚ฌ์šฉ์ž ์ผ์น˜ ํ™•์ธ ๋“ฑ์˜ ๋กœ์ง์ด ์ž˜ ๊ตฌํ˜„๋˜์–ด ์žˆ์Šต๋‹ˆ๋‹ค. ์˜ˆ์™ธ ์ฒ˜๋ฆฌ๋„ ์ ์ ˆํžˆ ์ด๋ฃจ์–ด์ง€๊ณ  ์žˆ์Šต๋‹ˆ๋‹ค.

์˜ˆ์™ธ ์ฒ˜๋ฆฌ๋ฅผ ๋”์šฑ ๋ช…ํ™•ํ•˜๊ฒŒ ํ•˜๊ธฐ ์œ„ํ•ด ๋‹ค์Œ๊ณผ ๊ฐ™์€ ๊ฐœ์„ ์„ ์ œ์•ˆํ•ฉ๋‹ˆ๋‹ค:

-        val user = userFacade.currentUser() ?: throw UserNotFoundException
-        val question = questionRepository.findById(questionId) ?: throw QuestionNotFoundException
+        val user = userFacade.currentUser() ?: throw UserNotFoundException()
+        val question = questionRepository.findById(questionId) ?: throw QuestionNotFoundException(questionId)
 
-        if (user != question.user) throw UserMisMatchException
+        if (user != question.user) throw UserMisMatchException(user.id, question.user.id)

์ด๋ ‡๊ฒŒ ํ•˜๋ฉด ์˜ˆ์™ธ์— ๋” ๋งŽ์€ ์ปจํ…์ŠคํŠธ ์ •๋ณด๋ฅผ ์ œ๊ณตํ•  ์ˆ˜ ์žˆ์–ด ๋””๋ฒ„๊น…์ด ์šฉ์ดํ•ด์ง‘๋‹ˆ๋‹ค.

src/main/kotlin/org/meogo/domain/question/domain/Question.kt (1)

33-35: questionType ์†์„ฑ์ด ์ ์ ˆํžˆ ์ถ”๊ฐ€๋˜์—ˆ์Šต๋‹ˆ๋‹ค.

QuestionType enum์„ ์‚ฌ์šฉํ•˜์—ฌ ํƒ€์ž… ์•ˆ์ •์„ฑ์„ ๊ฐœ์„ ํ•œ ๊ฒƒ์€ ์ข‹์€ ์ ‘๊ทผ์ž…๋‹ˆ๋‹ค. EnumType.STRING์„ ์‚ฌ์šฉํ•˜์—ฌ ๋ฐ์ดํ„ฐ๋ฒ ์ด์Šค์— ๋ฌธ์ž์—ด๋กœ ์ €์žฅํ•˜๋Š” ๊ฒƒ๋„ ์ ์ ˆํ•ฉ๋‹ˆ๋‹ค.

QuestionType enum์— ๋Œ€ํ•œ ๋ฌธ์„œํ™”๋ฅผ ์ถ”๊ฐ€ํ•˜๋Š” ๊ฒƒ์ด ์ข‹๊ฒ ์Šต๋‹ˆ๋‹ค. ๊ฐ enum ๊ฐ’์ด ์–ด๋–ค ์˜๋ฏธ๋ฅผ ๊ฐ€์ง€๋Š”์ง€ ์„ค๋ช…ํ•ด์ฃผ์„ธ์š”.

src/main/kotlin/org/meogo/domain/question/presentation/QuestionController.kt (4)

34-36: ๋ฐ˜ํ™˜ ํƒ€์ž… ๋ช…์‹œ๋ฅผ ํ†ตํ•œ ์ฝ”๋“œ ๋ช…ํ™•์„ฑ ํ–ฅ์ƒ

ํ˜„์žฌ createQuestion ํ•จ์ˆ˜๋Š” ๋ฐ˜ํ™˜ ํƒ€์ž…์„ ๋ช…์‹œํ•˜๊ณ  ์žˆ์ง€ ์•Š์Šต๋‹ˆ๋‹ค. ๋ช…์‹œ์ ์œผ๋กœ ๋ฐ˜ํ™˜ ํƒ€์ž…์„ ์ง€์ •ํ•˜๋ฉด ์ฝ”๋“œ์˜ ๊ฐ€๋…์„ฑ๊ณผ ์œ ์ง€๋ณด์ˆ˜์„ฑ์ด ํ–ฅ์ƒ๋ฉ๋‹ˆ๋‹ค.

์˜ˆ๋ฅผ ๋“ค์–ด:

@PostMapping
fun createQuestion(
    @Valid @RequestBody
    request: QuestionRequest
): ResponseEntity<Void> {
    createQuestionService.execute(request)
    return ResponseEntity.status(HttpStatus.CREATED).build()
}

38-46: RESTful API ์„ค๊ณ„ ์›์น™์— ๋”ฐ๋ฅธ Endpoint ์ˆ˜์ • ์ œ์•ˆ

@PatchMapping("/modify")์™€ @RequestParam์„ ์‚ฌ์šฉํ•˜๊ณ  ์žˆ๋Š”๋ฐ, RESTful ๊ด€๋ก€์— ๋”ฐ๋ผ @PatchMapping("/{questionId}")์™€ @PathVariable์„ ์‚ฌ์šฉํ•˜๋Š” ๊ฒƒ์ด ๋” ์ ์ ˆํ•ฉ๋‹ˆ๋‹ค.

์ฝ”๋“œ ์ˆ˜์ • ์˜ˆ์‹œ:

@PatchMapping("/{questionId}")
fun modifyQuestion(
    @PathVariable questionId: Long,
    @Valid @RequestBody
    request: ModifyQuestionRequest
) =
    modifyQuestionService.execute(questionId, request)

47-49: Endpoint ๋ช…๋ช… ๊ทœ์น™ ๊ฐœ์„ 

@GetMapping("/query")๋ณด๋‹ค ๋” ๋ช…ํ™•ํ•œ Endpoint๋ฅผ ์‚ฌ์šฉํ•˜๋ฉด ์‚ฌ์šฉ์ž ์ดํ•ด์— ๋„์›€์ด ๋ฉ๋‹ˆ๋‹ค. ์˜ˆ๋ฅผ ๋“ค์–ด, @GetMapping("/school/{schoolId}")์™€ ๊ฐ™์ด ์„ค์ •ํ•˜๊ณ  @PathVariable์„ ์‚ฌ์šฉํ•˜๋Š” ๊ฒƒ์ด ์ข‹์Šต๋‹ˆ๋‹ค.

์ฝ”๋“œ ์ˆ˜์ • ์˜ˆ์‹œ:

@GetMapping("/school/{schoolId}")
fun querySchoolQuestion(@PathVariable schoolId: Int) =
    querySchoolQuestionService.execute(schoolId)

51-54: DELETE ๋ฉ”์†Œ๋“œ์˜ Endpoint ๊ฐœ์„ 

@DeleteMapping("/delete") ๋Œ€์‹  @DeleteMapping("/{questionId}")์™€ @PathVariable์„ ์‚ฌ์šฉํ•˜์—ฌ RESTfulํ•œ API๋ฅผ ๊ตฌ์„ฑํ•˜๋Š” ๊ฒƒ์ด ์ข‹์Šต๋‹ˆ๋‹ค.

์ฝ”๋“œ ์ˆ˜์ • ์˜ˆ์‹œ:

@DeleteMapping("/{questionId}")
@ResponseStatus(HttpStatus.NO_CONTENT)
fun deleteQuestion(@PathVariable questionId: Long) =
    deleteQuestionService.execute(questionId)
๐Ÿ“œ Review details

Configuration used: CodeRabbit UI
Review profile: CHILL

๐Ÿ“ฅ Commits

Files that changed from the base of the PR and between f561264 and 1f4953c.

๐Ÿ“’ Files selected for processing (14)
  • src/main/kotlin/org/meogo/domain/comment/presentation/CommentController.kt (1 hunks)
  • src/main/kotlin/org/meogo/domain/question/domain/Question.kt (2 hunks)
  • src/main/kotlin/org/meogo/domain/question/domain/QuestionRepository.kt (1 hunks)
  • src/main/kotlin/org/meogo/domain/question/enum/QuestionType.kt (1 hunks)
  • src/main/kotlin/org/meogo/domain/question/presentation/QuestionController.kt (1 hunks)
  • src/main/kotlin/org/meogo/domain/question/presentation/dto/request/ModifyQuestionRequest.kt (1 hunks)
  • src/main/kotlin/org/meogo/domain/question/presentation/dto/request/QuestionRequest.kt (1 hunks)
  • src/main/kotlin/org/meogo/domain/question/presentation/dto/response/QuerySchoolQuestionResponse.kt (1 hunks)
  • src/main/kotlin/org/meogo/domain/question/service/CreateQuestionService.kt (1 hunks)
  • src/main/kotlin/org/meogo/domain/question/service/DeleteQuestionService.kt (1 hunks)
  • src/main/kotlin/org/meogo/domain/question/service/ModifyQuestionService.kt (1 hunks)
  • src/main/kotlin/org/meogo/domain/question/service/QuerySchoolQuestionService.kt (1 hunks)
  • src/main/kotlin/org/meogo/domain/review/presentation/dto/response/ReviewPictureResponse.kt (1 hunks)
  • src/main/kotlin/org/meogo/domain/review/service/QueryReviewPictureService.kt (1 hunks)
๐Ÿ”‡ Additional comments not posted (21)
src/main/kotlin/org/meogo/domain/question/presentation/dto/response/QuerySchoolQuestionResponse.kt (2)

1-1: ํŒจํ‚ค์ง€ ์„ ์–ธ์ด ์ ์ ˆํ•ฉ๋‹ˆ๋‹ค.

ํŒจํ‚ค์ง€ ์ด๋ฆ„์ด Kotlin ๋ช…๋ช… ๊ทœ์น™์„ ๋”ฐ๋ฅด๊ณ  ์žˆ์œผ๋ฉฐ, ํ”„๋ ˆ์  ํ…Œ์ด์…˜ ๊ณ„์ธต์˜ ์‘๋‹ต DTO์— ๋Œ€ํ•œ ๊ตฌ์กฐ๋ฅผ ์ž˜ ๋‚˜ํƒ€๋‚ด๊ณ  ์žˆ์Šต๋‹ˆ๋‹ค.


3-3: import ๋ฌธ์ด ์ ์ ˆํ•ฉ๋‹ˆ๋‹ค.

QuestionType์„ ๋ฐ์ดํ„ฐ ํด๋ž˜์Šค์—์„œ ์‚ฌ์šฉํ•˜๊ณ  ์žˆ์œผ๋ฏ€๋กœ ์ด import ๋ฌธ์€ ํ•„์š”ํ•ฉ๋‹ˆ๋‹ค. QuestionType์ด enum ํด๋ž˜์Šค์ธ ๊ฒƒ์œผ๋กœ ๋ณด์ด๋ฉฐ, ์ด๋Š” ๋‹ค์–‘ํ•œ ์งˆ๋ฌธ ์œ ํ˜•์„ ํ‘œํ˜„ํ•˜๋Š” ๋ฐ ์ ํ•ฉํ•ฉ๋‹ˆ๋‹ค.

src/main/kotlin/org/meogo/domain/question/presentation/dto/request/ModifyQuestionRequest.kt (2)

1-4: ํŒจํ‚ค์ง€ ์„ ์–ธ๊ณผ ์ž„ํฌํŠธ๊ฐ€ ์ ์ ˆํ•ฉ๋‹ˆ๋‹ค.

ํŒจํ‚ค์ง€ ์ด๋ฆ„์ด Kotlin ๋ช…๋ช… ๊ทœ์น™์„ ๋”ฐ๋ฅด๊ณ  ์žˆ์œผ๋ฉฐ, ์งˆ๋ฌธ ๋„๋ฉ”์ธ์˜ DTO์— ์ ํ•ฉํ•ด ๋ณด์ž…๋‹ˆ๋‹ค. QuestionType enum๊ณผ Size ์ œ์•ฝ ์กฐ๊ฑด์— ๋Œ€ํ•œ ์ž„ํฌํŠธ๊ฐ€ ์˜ฌ๋ฐ”๋ฅด๊ฒŒ ์‚ฌ์šฉ๋˜์—ˆ์Šต๋‹ˆ๋‹ค.


6-6: ๋ฐ์ดํ„ฐ ํด๋ž˜์Šค ์„ ์–ธ์ด ์ ์ ˆํ•ฉ๋‹ˆ๋‹ค.

ModifyQuestionRequest๋ผ๋Š” ํด๋ž˜์Šค ์ด๋ฆ„์ด ์งˆ๋ฌธ ์ˆ˜์ •์„ ์œ„ํ•œ ์š”์ฒญ ๊ฐ์ฒด์˜ ๋ชฉ์ ์„ ๋ช…ํ™•ํžˆ ๋‚˜ํƒ€๋‚ด๊ณ  ์žˆ์Šต๋‹ˆ๋‹ค. DTO์— ๋ฐ์ดํ„ฐ ํด๋ž˜์Šค๋ฅผ ์‚ฌ์šฉํ•œ ๊ฒƒ์€ ์ ์ ˆํ•œ ์„ ํƒ์ž…๋‹ˆ๋‹ค.

src/main/kotlin/org/meogo/domain/question/domain/QuestionRepository.kt (3)

6-6: LGTM: save ๋ฉ”์†Œ๋“œ๊ฐ€ ์˜ฌ๋ฐ”๋ฅด๊ฒŒ ์ถ”๊ฐ€๋˜์—ˆ์Šต๋‹ˆ๋‹ค.

save ๋ฉ”์†Œ๋“œ์˜ ์„œ๋ช…์ด Spring Data ๊ทœ์น™์„ ๋”ฐ๋ฅด๊ณ  ์žˆ์œผ๋ฉฐ, Question ๊ฐ์ฒด๋ฅผ ์ €์žฅํ•˜๋Š” ๋ฐ ์ ํ•ฉํ•ฉ๋‹ˆ๋‹ค.


12-12: LGTM: deleteById ๋ฉ”์†Œ๋“œ๊ฐ€ ์˜ฌ๋ฐ”๋ฅด๊ฒŒ ์ถ”๊ฐ€๋˜์—ˆ์Šต๋‹ˆ๋‹ค.

deleteById ๋ฉ”์†Œ๋“œ์˜ ์„œ๋ช…์ด Spring Data ๊ทœ์น™์„ ๋”ฐ๋ฅด๊ณ  ์žˆ์œผ๋ฉฐ, ID๋ฅผ ๊ธฐ๋ฐ˜์œผ๋กœ Question ๊ฐ์ฒด๋ฅผ ์‚ญ์ œํ•˜๋Š” ๋ฐ ์ ํ•ฉํ•ฉ๋‹ˆ๋‹ค.


Line range hint 1-13: PR ๋ชฉํ‘œ์— ๋ถ€ํ•ฉํ•˜๋Š” Question CRUD ๊ธฐ๋Šฅ์ด ์„ฑ๊ณต์ ์œผ๋กœ ๊ตฌํ˜„๋˜์—ˆ์Šต๋‹ˆ๋‹ค.

QuestionRepository ์ธํ„ฐํŽ˜์ด์Šค์— ์ถ”๊ฐ€๋œ ๋ฉ”์†Œ๋“œ๋“ค์€ PR์˜ ๋ชฉํ‘œ์ธ ์งˆ๋ฌธ์— ๋Œ€ํ•œ CRUD ๊ธฐ๋Šฅ์„ ์ž˜ ๊ตฌํ˜„ํ•˜๊ณ  ์žˆ์Šต๋‹ˆ๋‹ค. save, findById, findBySchoolId, deleteById ๋ฉ”์†Œ๋“œ๋“ค์ด ์ถ”๊ฐ€๋˜์–ด ๊ธฐ๋ณธ์ ์ธ CRUD ์ž‘์—…์„ ์ˆ˜ํ–‰ํ•  ์ˆ˜ ์žˆ๊ฒŒ ๋˜์—ˆ์Šต๋‹ˆ๋‹ค.

์ด ๋ณ€๊ฒฝ์‚ฌํ•ญ๋“ค์€ Spring Data์˜ ๊ทœ์น™์„ ์ž˜ ๋”ฐ๋ฅด๊ณ  ์žˆ์œผ๋ฉฐ, ์ „๋ฐ˜์ ์œผ๋กœ ์ž˜ ๊ตฌํ˜„๋˜์—ˆ์Šต๋‹ˆ๋‹ค. ๋‹จ, findBySchoolId ๋ฉ”์†Œ๋“œ์˜ ๋ฐ˜ํ™˜ ํƒ€์ž…๊ณผ ๋งค๊ฐœ๋ณ€์ˆ˜ ํƒ€์ž…์— ๋Œ€ํ•ด ์ œ์•ˆํ•œ ๊ฐœ์„ ์‚ฌํ•ญ์„ ๊ณ ๋ คํ•ด๋ณด์‹œ๊ธฐ ๋ฐ”๋ž๋‹ˆ๋‹ค.

์ด๋Ÿฌํ•œ ๋ณ€๊ฒฝ์‚ฌํ•ญ๋“ค์€ PR์—์„œ ์–ธ๊ธ‰๋œ ์งˆ๋ฌธ ๊ด€๋ฆฌ ๊ธฐ๋Šฅ์„ ํšจ๊ณผ์ ์œผ๋กœ ์ง€์›ํ•  ๊ฒƒ์œผ๋กœ ๋ณด์ž…๋‹ˆ๋‹ค.

src/main/kotlin/org/meogo/domain/question/presentation/dto/request/QuestionRequest.kt (2)

1-11: ์ „๋ฐ˜์ ์ธ ๊ตฌ์กฐ๊ฐ€ ์ž˜ ์„ค๊ณ„๋˜์—ˆ์Šต๋‹ˆ๋‹ค.

์ด ๋ฐ์ดํ„ฐ ํด๋ž˜์Šค๋Š” ์งˆ๋ฌธ ์š”์ฒญ์„ ์œ„ํ•œ DTO๋กœ ์ž˜ ๊ตฌ์„ฑ๋˜์–ด ์žˆ์Šต๋‹ˆ๋‹ค. ๊ฐ ํ•„๋“œ์˜ ํƒ€์ž…์ด ์ ์ ˆํ•˜๊ฒŒ ์„ ํƒ๋˜์—ˆ์œผ๋ฉฐ, ํ•„์š”ํ•œ import ๋ฌธ๋„ ์˜ฌ๋ฐ”๋ฅด๊ฒŒ ํฌํ•จ๋˜์–ด ์žˆ์Šต๋‹ˆ๋‹ค.


8-9: content ํ•„๋“œ์˜ ํฌ๊ธฐ ์ œํ•œ์ด ์ ์ ˆํ•ฉ๋‹ˆ๋‹ค.

content ํ•„๋“œ์— ๋Œ€ํ•œ ํฌ๊ธฐ ์ œํ•œ(1-100์ž)์€ ์ ์ ˆํ•œ ๊ฒƒ์œผ๋กœ ๋ณด์ž…๋‹ˆ๋‹ค. ์ด๋Š” ๋„ˆ๋ฌด ์งง๊ฑฐ๋‚˜ ๊ธด ์งˆ๋ฌธ ๋‚ด์šฉ์„ ๋ฐฉ์ง€ํ•˜๋Š” ๋ฐ ๋„์›€์ด ๋  ๊ฒƒ์ž…๋‹ˆ๋‹ค.

src/main/kotlin/org/meogo/domain/question/service/DeleteQuestionService.kt (1)

1-9: ํŒจํ‚ค์ง€ ์„ ์–ธ ๋ฐ ์ž„ํฌํŠธ๊ฐ€ ์ ์ ˆํ•ฉ๋‹ˆ๋‹ค.

ํŒจํ‚ค์ง€ ์„ ์–ธ๊ณผ ์ž„ํฌํŠธ ๋ฌธ์ด ์˜ฌ๋ฐ”๋ฅด๊ฒŒ ์ž‘์„ฑ๋˜์—ˆ์Šต๋‹ˆ๋‹ค. ํ•„์š”ํ•œ ๋ชจ๋“  ์˜์กด์„ฑ์ด ํฌํ•จ๋˜์–ด ์žˆ์œผ๋ฉฐ ๋ถˆํ•„์š”ํ•œ ์ž„ํฌํŠธ๋Š” ์—†์Šต๋‹ˆ๋‹ค.

src/main/kotlin/org/meogo/domain/question/service/QuerySchoolQuestionService.kt (2)

8-11: ํด๋ž˜์Šค ๊ตฌ์กฐ๊ฐ€ ์ ์ ˆํ•ฉ๋‹ˆ๋‹ค.

์„œ๋น„์Šค ํด๋ž˜์Šค์˜ ๊ตฌ์กฐ๊ฐ€ Spring ๋ชจ๋ฒ” ์‚ฌ๋ก€๋ฅผ ์ž˜ ๋”ฐ๋ฅด๊ณ  ์žˆ์Šต๋‹ˆ๋‹ค. @Service ์–ด๋…ธํ…Œ์ด์…˜๊ณผ ์ƒ์„ฑ์ž ์ฃผ์ž…์„ ์˜ฌ๋ฐ”๋ฅด๊ฒŒ ์‚ฌ์šฉํ•˜๊ณ  ์žˆ์Šต๋‹ˆ๋‹ค.


13-26: โš ๏ธ Potential issue

execute ๋ฉ”์„œ๋“œ ๊ตฌํ˜„์— ๋Œ€ํ•œ ๋ช‡ ๊ฐ€์ง€ ๊ณ ๋ ค์‚ฌํ•ญ

  1. findBySchoolId ๋ฉ”์„œ๋“œ๊ฐ€ null์„ ๋ฐ˜ํ™˜ํ•  ์ˆ˜ ์žˆ๋Š” ๊ฒƒ์œผ๋กœ ๋ณด์ž…๋‹ˆ๋‹ค. ์ผ๋ฐ˜์ ์œผ๋กœ ๋ฆฌํฌ์ง€ํ† ๋ฆฌ ๋ฉ”์„œ๋“œ๋Š” ๋นˆ ์ปฌ๋ ‰์…˜์„ ๋ฐ˜ํ™˜ํ•˜๋Š” ๊ฒƒ์ด ์ข‹์Šต๋‹ˆ๋‹ค.

๋‹ค์Œ ์Šคํฌ๋ฆฝํŠธ๋ฅผ ์‹คํ–‰ํ•˜์—ฌ QuestionRepository ์ธํ„ฐํŽ˜์ด์Šค๋ฅผ ํ™•์ธํ•ด ์ฃผ์„ธ์š”:

  1. question.format(question.date)์—์„œ format ๋ฉ”์„œ๋“œ์˜ ์ถœ์ฒ˜๊ฐ€ ๋ช…ํ™•ํ•˜์ง€ ์•Š์Šต๋‹ˆ๋‹ค. ์ด ๋ฉ”์„œ๋“œ๊ฐ€ Question ํด๋ž˜์Šค์˜ ํ™•์žฅ ํ•จ์ˆ˜์ธ์ง€ ํ™•์ธํ•ด ์ฃผ์„ธ์š”.

  2. ์‘๋‹ต์˜ name ํ•„๋“œ์— accountId๋ฅผ ์‚ฌ์šฉํ•˜๊ณ  ์žˆ์Šต๋‹ˆ๋‹ค. ์ด๊ฒƒ์ด ์˜๋„๋œ ๊ฒƒ์ธ์ง€, ์•„๋‹ˆ๋ฉด ์‹ค์ œ ์ด๋ฆ„์„ ์‚ฌ์šฉํ•ด์•ผ ํ•˜๋Š”์ง€ ํ™•์ธํ•ด ์ฃผ์„ธ์š”.

์ด๋Ÿฌํ•œ ์ ๋“ค์„ ๊ฒ€ํ† ํ•˜๊ณ  ํ•„์š”ํ•œ ๊ฒฝ์šฐ ์ˆ˜์ •ํ•ด ์ฃผ์‹œ๊ธฐ ๋ฐ”๋ž๋‹ˆ๋‹ค.

src/main/kotlin/org/meogo/domain/review/service/QueryReviewPictureService.kt (3)

22-22: ์—ฐ๋„ ๋ณ€์ˆ˜ ์ถ”์ถœ์ด ์ž˜ ๋˜์—ˆ์Šต๋‹ˆ๋‹ค.

year ๋ณ€์ˆ˜๋ฅผ ์ถ”์ถœํ•˜์—ฌ ์‚ฌ์šฉํ•˜๋Š” ๊ฒƒ์€ ์ข‹์€ ๋ฐฉ๋ฒ•์ž…๋‹ˆ๋‹ค. ์ด๋Š” ์ฝ”๋“œ์˜ ๊ฐ€๋…์„ฑ์„ ๋†’์ด๊ณ  ์œ ์ง€๋ณด์ˆ˜๋ฅผ ์šฉ์ดํ•˜๊ฒŒ ํ•ฉ๋‹ˆ๋‹ค.


22-25: ์ „๋ฐ˜์ ์ธ ๋ณ€๊ฒฝ ์‚ฌํ•ญ์ด ์ž˜ ๊ตฌํ˜„๋˜์—ˆ์Šต๋‹ˆ๋‹ค.

์—ฐ๋„ ์ •๋ณด๋ฅผ ReviewPictureResponse์— ํฌํ•จ์‹œํ‚ค๋Š” ๋ณ€๊ฒฝ์€ ์ ์ ˆํ•˜๊ฒŒ ๊ตฌํ˜„๋˜์—ˆ์Šต๋‹ˆ๋‹ค. ์ด ๋ณ€๊ฒฝ์œผ๋กœ ์ธํ•ด ๋ฆฌ๋ทฐ ์‚ฌ์ง„๊ณผ ๊ด€๋ จ๋œ ๋ฐ์ดํ„ฐ์˜ ์‹œ๊ฐ„์  ์ปจํ…์ŠคํŠธ๊ฐ€ ๊ฐœ์„ ๋˜์—ˆ์Šต๋‹ˆ๋‹ค. ๋‹ค๋งŒ, ์ด ๋ณ€๊ฒฝ์œผ๋กœ ์ธํ•ด ReviewPictureResponse๋ฅผ ์‚ฌ์šฉํ•˜๋Š” ๋‹ค๋ฅธ ๋ถ€๋ถ„๋“ค๋„ ์—…๋ฐ์ดํŠธ๊ฐ€ ํ•„์š”ํ•  ์ˆ˜ ์žˆ์œผ๋ฏ€๋กœ, ์ „์ฒด ์ฝ”๋“œ๋ฒ ์ด์Šค์—์„œ ์ด ๋ณ€๊ฒฝ์˜ ์˜ํ–ฅ์„ ํ™•์ธํ•˜๋Š” ๊ฒƒ์ด ์ข‹๊ฒ ์Šต๋‹ˆ๋‹ค.


25-25: ReviewPictureResponse ์ƒ์„ฑ์ž ๋ณ€๊ฒฝ์ด ์ ์ ˆํžˆ ์ด๋ฃจ์–ด์กŒ์Šต๋‹ˆ๋‹ค.

ReviewPictureResponse ์ƒ์„ฑ์ž์— year ๋งค๊ฐœ๋ณ€์ˆ˜๋ฅผ ์ถ”๊ฐ€ํ•œ ๊ฒƒ์€ ์ ์ ˆํ•ฉ๋‹ˆ๋‹ค. ์ด๋Š” AI ์š”์•ฝ์—์„œ ์–ธ๊ธ‰๋œ ๋ฐ์ดํ„ฐ ๊ตฌ์กฐ ๋ณ€๊ฒฝ๊ณผ ์ผ์น˜ํ•ฉ๋‹ˆ๋‹ค.

๋‹ค์Œ ์Šคํฌ๋ฆฝํŠธ๋ฅผ ์‹คํ–‰ํ•˜์—ฌ ReviewPictureResponse์˜ ์‚ฌ์šฉ์„ ํ™•์ธํ•˜์„ธ์š”:

โœ… Verification successful

ReviewPictureResponse ์ƒ์„ฑ์ž ๋ณ€๊ฒฝ์ด ์„ฑ๊ณต์ ์œผ๋กœ ๊ฒ€์ฆ๋˜์—ˆ์Šต๋‹ˆ๋‹ค.

ReviewPictureResponse ์ƒ์„ฑ์ž์— year ๋งค๊ฐœ๋ณ€์ˆ˜๋ฅผ ์ถ”๊ฐ€ํ•˜๊ณ  image ๋งค๊ฐœ๋ณ€์ˆ˜๋กœ pictureUrl์ด ์˜ฌ๋ฐ”๋ฅด๊ฒŒ ์ „๋‹ฌ๋˜๊ณ  ์žˆ์Œ์„ ํ™•์ธํ–ˆ์Šต๋‹ˆ๋‹ค. ์ฝ”๋“œ ์ „๋ฐ˜์— ๊ฑธ์ณ ์ถ”๊ฐ€์ ์ธ ์ˆ˜์ •์ด ํ•„์š”ํ•˜์ง€ ์•Š์Šต๋‹ˆ๋‹ค.

๐Ÿ Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Description: `ReviewPictureResponse` ์‚ฌ์šฉ ํ™•์ธ

# Test: `ReviewPictureResponse` ์‚ฌ์šฉ ๊ฒ€์ƒ‰. ์˜ˆ์ƒ ๊ฒฐ๊ณผ: ์ƒˆ๋กœ์šด ์ƒ์„ฑ์ž ์„œ๋ช…๋งŒ ๋‚˜ํƒ€๋‚˜์•ผ ํ•จ.
rg --type kotlin -A 5 $'ReviewPictureResponse'

Length of output: 2578

src/main/kotlin/org/meogo/domain/question/service/CreateQuestionService.kt (2)

1-11: ํŒจํ‚ค์ง€ ์„ ์–ธ ๋ฐ ์ž„ํฌํŠธ๊ฐ€ ์ ์ ˆํ•ฉ๋‹ˆ๋‹ค.

ํŒจํ‚ค์ง€ ์„ ์–ธ๊ณผ ์ž„ํฌํŠธ ๋ฌธ์ด ์ž˜ ๊ตฌ์„ฑ๋˜์–ด ์žˆ์Šต๋‹ˆ๋‹ค. ํ•„์š”ํ•œ ๋ชจ๋“  ํด๋ž˜์Šค์™€ ์ธํ„ฐํŽ˜์ด์Šค๊ฐ€ ์ž„ํฌํŠธ๋˜์–ด ์žˆ์œผ๋ฉฐ, ๋ถˆํ•„์š”ํ•œ ์ž„ํฌํŠธ๋Š” ์—†์Šต๋‹ˆ๋‹ค.


18-31: execute ๋ฉ”์„œ๋“œ ๊ตฌํ˜„์ด ์ „๋ฐ˜์ ์œผ๋กœ ์ž˜ ๋˜์–ด ์žˆ์Šต๋‹ˆ๋‹ค.

ํŠธ๋žœ์žญ์…˜ ์ฒ˜๋ฆฌ์™€ ์‚ฌ์šฉ์ž ํ™•์ธ์ด ์ ์ ˆํžˆ ๊ตฌํ˜„๋˜์–ด ์žˆ์Šต๋‹ˆ๋‹ค. ๊ทธ๋Ÿฌ๋‚˜ ๋‹ค์Œ ์‚ฌํ•ญ์„ ๊ณ ๋ คํ•ด ๋ณด์‹œ๊ธฐ ๋ฐ”๋ž๋‹ˆ๋‹ค:

request.schoolId๊ฐ€ ์œ ํšจํ•œ ๊ฐ’์ธ์ง€ ํ™•์ธํ•˜๋Š” ๋กœ์ง์ด ์—†์Šต๋‹ˆ๋‹ค. ์ž˜๋ชป๋œ schoolId๊ฐ€ ์ž…๋ ฅ๋  ๊ฒฝ์šฐ ๋ฌธ์ œ๊ฐ€ ๋ฐœ์ƒํ•  ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค. ๋‹ค์Œ๊ณผ ๊ฐ™์€ ๊ฒ€์ฆ ๋กœ์ง์„ ์ถ”๊ฐ€ํ•˜๋Š” ๊ฒƒ์ด ์ข‹๊ฒ ์Šต๋‹ˆ๋‹ค:

val school = schoolRepository.findById(request.schoolId)
    ?: throw SchoolNotFoundException("School not found with id: ${request.schoolId}")

์ด๋ฅผ ์œ„ํ•ด SchoolRepository์™€ SchoolNotFoundException์„ ์ถ”๊ฐ€๋กœ ๊ตฌํ˜„ํ•ด์•ผ ํ•  ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.

๋‹ค์Œ ์Šคํฌ๋ฆฝํŠธ๋ฅผ ์‹คํ–‰ํ•˜์—ฌ SchoolRepository์™€ SchoolNotFoundException์˜ ์กด์žฌ ์—ฌ๋ถ€๋ฅผ ํ™•์ธํ•  ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค:

src/main/kotlin/org/meogo/domain/question/service/ModifyQuestionService.kt (2)

1-11: ํŒจํ‚ค์ง€ ์„ ์–ธ ๋ฐ ์ž„ํฌํŠธ๊ฐ€ ์ ์ ˆํ•ฉ๋‹ˆ๋‹ค.

ํŒจํ‚ค์ง€ ์„ ์–ธ๊ณผ ์ž„ํฌํŠธ๋œ ํด๋ž˜์Šค๋“ค์ด ModifyQuestionService์˜ ๊ธฐ๋Šฅ์— ์ ํ•ฉํ•˜๊ฒŒ ๊ตฌ์„ฑ๋˜์–ด ์žˆ์Šต๋‹ˆ๋‹ค. ๋ถˆํ•„์š”ํ•œ ์ž„ํฌํŠธ๋Š” ์—†์œผ๋ฉฐ, ํ•„์š”ํ•œ ๋ชจ๋“  ํด๋ž˜์Šค๊ฐ€ ์ž„ํฌํŠธ๋˜์–ด ์žˆ์Šต๋‹ˆ๋‹ค.


1-29: ์ „๋ฐ˜์ ์œผ๋กœ ์ž˜ ๊ตฌํ˜„๋œ ์„œ๋น„์Šค ํด๋ž˜์Šค์ž…๋‹ˆ๋‹ค.

ModifyQuestionService ํด๋ž˜์Šค๋Š” ์งˆ๋ฌธ ์ˆ˜์ • ๊ธฐ๋Šฅ์„ ์ ์ ˆํ•˜๊ฒŒ ๊ตฌํ˜„ํ•˜๊ณ  ์žˆ์Šต๋‹ˆ๋‹ค. ์˜์กด์„ฑ ์ฃผ์ž…, ํŠธ๋žœ์žญ์…˜ ๊ด€๋ฆฌ, ์˜ˆ์™ธ ์ฒ˜๋ฆฌ ๋“ฑ์ด ์ž˜ ๊ตฌํ˜„๋˜์–ด ์žˆ์œผ๋ฉฐ, ์ฝ”๋“œ ๊ตฌ์กฐ์™€ ๋กœ์ง ํ๋ฆ„์ด ๋ช…ํ™•ํ•ฉ๋‹ˆ๋‹ค. ์ œ์•ˆ๋œ ์ž‘์€ ๊ฐœ์„ ์‚ฌํ•ญ๋“ค์„ ์ ์šฉํ•˜๋ฉด ๋”์šฑ ๊ฒฌ๊ณ ํ•œ ์ฝ”๋“œ๊ฐ€ ๋  ๊ฒƒ์ž…๋‹ˆ๋‹ค.

src/main/kotlin/org/meogo/domain/question/domain/Question.kt (2)

3-3: ์ƒˆ๋กœ์šด ์ž„ํฌํŠธ๊ฐ€ ์ ์ ˆํžˆ ์ถ”๊ฐ€๋˜์—ˆ์Šต๋‹ˆ๋‹ค.

์ƒˆ๋กœ ์ถ”๊ฐ€๋œ ์ž„ํฌํŠธ๋“ค์€ ํด๋ž˜์Šค์— ๋„์ž…๋œ ์ƒˆ๋กœ์šด ๊ธฐ๋Šฅ์„ ์ง€์›ํ•˜๊ธฐ ์œ„ํ•ด ํ•„์š”ํ•ฉ๋‹ˆ๋‹ค. QuestionType enum์˜ ์‚ฌ์šฉ์€ ํƒ€์ž… ์•ˆ์ •์„ฑ์„ ํ–ฅ์ƒ์‹œํ‚ฌ ๊ฒƒ์ž…๋‹ˆ๋‹ค.

Also applies to: 6-6, 9-10


41-45: modify ๋ฉ”์„œ๋“œ๊ฐ€ ์ถ”๊ฐ€๋˜์—ˆ์Šต๋‹ˆ๋‹ค.

modify ๋ฉ”์„œ๋“œ๋ฅผ ํ†ตํ•ด content์™€ questionType์„ ์‰ฝ๊ฒŒ ์ˆ˜์ •ํ•  ์ˆ˜ ์žˆ๊ฒŒ ๋œ ๊ฒƒ์€ ์ข‹์Šต๋‹ˆ๋‹ค. ์ˆ˜์ •๋œ ์ธ์Šคํ„ด์Šค๋ฅผ ๋ฐ˜ํ™˜ํ•˜๋Š” ๊ฒƒ๋„ ๋ฉ”์„œ๋“œ ์ฒด์ด๋‹์„ ๊ฐ€๋Šฅํ•˜๊ฒŒ ํ•˜์—ฌ ์ข‹์€ ๋ฐฉ์‹์ž…๋‹ˆ๋‹ค.

์ด ๋ฉ”์„œ๋“œ๊ฐ€ ๋ณ€๊ฒฝ์‚ฌํ•ญ์„ ์˜๊ตฌ์ ์œผ๋กœ ์ €์žฅํ•˜๋Š” ์—ญํ• ๋„ ๋‹ด๋‹นํ•ด์•ผ ํ•˜๋Š”์ง€ ํ™•์ธ์ด ํ•„์š”ํ•ฉ๋‹ˆ๋‹ค. ๋‹ค์Œ ์Šคํฌ๋ฆฝํŠธ๋ฅผ ์‹คํ–‰ํ•˜์—ฌ ์ด ๋ฉ”์„œ๋“œ์˜ ์‚ฌ์šฉ์„ ํ™•์ธํ•ด ์ฃผ์„ธ์š”:

#!/bin/bash
# `modify` ๋ฉ”์„œ๋“œ์˜ ์‚ฌ์šฉ์„ ํ™•์ธํ•ฉ๋‹ˆ๋‹ค.
rg --type kotlin "\.modify\(" -g '!Question.kt'

@meltapplee meltapplee merged commit 626cc12 into main Sep 25, 2024
2 checks passed
@meltapplee meltapplee deleted the 38-question-crud branch October 18, 2024 03:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

์งˆ๋ฌธ ์ž‘์„ฑ, ์ˆ˜์ • ์‚ญ์ œ, ์กฐํšŒ
1 participant