Skip to content

Commit

Permalink
add: (#78) Response 제거
Browse files Browse the repository at this point in the history
  • Loading branch information
khcho0125 committed Sep 25, 2022
1 parent 05d37ee commit 5e441f3
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 22 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ class SendAuthCodeUseCase(
private val sendEmailPort: SendEmailPort
) {

fun execute(email: String): Short {
val authCodeLimit = commandAuthCodeLimitPort.save(
fun execute(email: String) {
commandAuthCodeLimitPort.save(
sendAuthCodePolicy.restriction(email)
)

Expand All @@ -32,8 +32,6 @@ class SendAuthCodeUseCase(
)

sendEmailPort.sendAuthCode(authCode.code, email)

return authCodeLimit.attemptCount
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ import team.comit.simtong.domain.auth.usecase.CheckAuthCodeUseCase
import team.comit.simtong.domain.auth.usecase.SendAuthCodeUseCase
import team.comit.simtong.email.dto.request.WebCheckAuthCodeRequest
import team.comit.simtong.email.dto.request.WebSendAuthCodeRequest
import team.comit.simtong.email.dto.response.WebRemainChanceResponse
import javax.validation.Valid

/**
Expand All @@ -28,10 +27,8 @@ class WebEmailAdapter(
) {

@PostMapping("/code")
fun sendAuthCode(@Valid @RequestBody request: WebSendAuthCodeRequest): WebRemainChanceResponse {
return WebRemainChanceResponse(
sendAuthCodeUseCase.execute(request.email)
)
fun sendAuthCode(@Valid @RequestBody request: WebSendAuthCodeRequest) {
sendAuthCodeUseCase.execute(request.email)
}

@GetMapping
Expand Down
Empty file.

This file was deleted.

0 comments on commit 5e441f3

Please sign in to comment.