-
Notifications
You must be signed in to change notification settings - Fork 1
[FEAT] 등록자 확인용 직전 등록 공연 조회 api추가 #151
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
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
|
|
@@ -271,7 +271,7 @@ public static AmateurShowResponseDTO.AmateurShowResult toResponseDTO(AmateurShow | |||||
| //.place(amateurShow.getPlace()) | ||||||
| .posterImageUrl(amateurShow.getPosterImageUrl()) | ||||||
| .schedule(schedule) | ||||||
| .runtime(amateurShow.getRuntime()) | ||||||
| .runtime(amateurShow.getRuntime() + "분") | ||||||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Null
🐛 Proposed fix- .runtime(amateurShow.getRuntime() + "분")
+ .runtime(amateurShow.getRuntime() != null ? amateurShow.getRuntime() + "분" : null)📝 Committable suggestion
Suggested change
🤖 Prompt for AI Agents |
||||||
| .account(amateurShow.getAccount()) | ||||||
| .contact(amateurShow.getContact()) | ||||||
| .hashtag(amateurShow.getHashtag()) | ||||||
|
|
||||||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🛠️ Refactor suggestion | 🟠 Major
🧩 Analysis chain
🏁 Script executed:
rg -n "getCreatedShow" --type=java -A 15Repository: SeeATheater/CC_Backend
Length of output: 5440
Fix misleading error code in service layer.
The endpoint is properly secured with
@PreAuthorize("hasRole('PERFORMER')")and correctly extracts the authenticated member. However, the service throwsErrorStatus.MEMBER_NOT_PERFORMERwhen the show isn't found for that member (line 461 inAmateurServiceImpl.java). This error code is semantically incorrect — the member is a performer (they passed the role check); the real issue is the show doesn't exist or isn't owned by that member. UseSHOW_NOT_FOUNDorSHOW_NOT_OWNED_BY_MEMBERinstead.🤖 Prompt for AI Agents