-
Notifications
You must be signed in to change notification settings - Fork 0
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
레시피 업로드 Domain, Data 영역을 정의해 보았습니다. #18
Conversation
import RxSwift | ||
|
||
protocol AddRecipeInteractorDelegate: AnyObject { | ||
func didLoadRecipeData(viewModel: AddRecipeViewModel) |
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.
didLoadRecipe 정도로 해도 괜찮을 것 같아요. viewModel을 넘겨서 구성하는데 너무 도메인적인 네이밍 같아요.
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.
[58b4cc8] 수정했습니다
) -> Single<Result<Recipe, AddRecipeError>> | ||
} | ||
|
||
class AddRecipeUseCaseImpl: AddRecipeUseCase { |
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.
final class 검토부탁해요
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.
[54cdfca] 수정했습니다
guard !images.isEmpty else { | ||
return .just(.failure(.noImages)) | ||
} | ||
|
||
guard !title.isBlank else { | ||
return .just(.failure(.titleIsEmpty)) | ||
} | ||
|
||
guard description.count > 10 else { | ||
return .just(.failure(.descriptionTooShort)) | ||
} |
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.
좋네요 👍
) | ||
-> Single<T> { |
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.
여긴 왜 줄바꿈하셨나요?
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.
어떤식으로 줄바꿈 해야할지 몰라서 저런식으로 한건데 저 부분은 50번째 줄로 올리겠습니다!
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.
[ed32a83] 수정했습니다
) | ||
} | ||
|
||
formDataRequest.finalize() |
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.
for문 내에서 하지 않고 밖에서 하는 이유가 있을까요?
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.
finalize는 전체 요청이 완성된후 1번만 호출되어야 하기 떄문입니다
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.
수고많으셨어요~ 오늘 말씀드린 레이어간의 네이밍도 추후 개선해주시면 좋을 것 같습니다.
Quality Gate passedIssues Measures |
레시피 업로드 도메인 영역 정의
레시피 업로드 데이터 영역 정의