Skip to content

Commit

Permalink
refactor: 정적 팩토리 메서드 네이밍 수정
Browse files Browse the repository at this point in the history
- 하나의 인자를 가지고 있는 정적 팩토리 메서드의 이름을 from으로 변경

#1474
  • Loading branch information
amaran-th committed Aug 16, 2023
1 parent 5275a7a commit bae8616
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ public EssayAnswerQuizResponse(Long quizId, String question) {
this.question = question;
}

public static EssayAnswerQuizResponse of(Quiz quiz) {
public static EssayAnswerQuizResponse from(Quiz quiz) {
return new EssayAnswerQuizResponse(quiz.getId(), quiz.getQuestion());
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ public static EssayAnswerResponse of(EssayAnswer essayAnswer) {
EssayAnswerResponse response = new EssayAnswerResponse();

response.id = essayAnswer.getId();
response.quiz = EssayAnswerQuizResponse.of(essayAnswer.getQuiz());
response.quiz = EssayAnswerQuizResponse.from(essayAnswer.getQuiz());
response.answer = essayAnswer.getAnswer();
response.author = MemberResponse.of(essayAnswer.getMember());
response.createdAt = essayAnswer.getCreatedAt();
Expand Down

0 comments on commit bae8616

Please sign in to comment.