Skip to content

Commit

Permalink
#68 fix: BaseResponse 생성자 추가
Browse files Browse the repository at this point in the history
  • Loading branch information
sojungpp committed Aug 6, 2023
1 parent c86fb2f commit 795341b
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/main/kotlin/com/psr/psr/global/dto/BaseResponse.kt
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,10 @@ class BaseResponse<T> {
this.code = code
this.message = message
}
constructor(baseResponseCode: BaseResponseCode) {
this.code = baseResponseCode.status.value()
this.message = baseResponseCode.message
}

companion object {
fun error(code: Int, message: String): BaseResponse<*> {
Expand Down

0 comments on commit 795341b

Please sign in to comment.