Skip to content

Commit

Permalink
[#89] rename: 공통 응답 모델 클래스명 수정
Browse files Browse the repository at this point in the history
  • Loading branch information
yeseul106 committed Dec 4, 2023
1 parent 7a2a611 commit 06382b3
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 28 deletions.

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
package org.sopt.makers.crew.main.common.response;

import com.fasterxml.jackson.annotation.JsonInclude;
import lombok.Builder;
import lombok.Getter;

@Builder
@Getter
@JsonInclude(JsonInclude.Include.NON_NULL)
public class CommonResponseDto<T> {

private final String errorCode;
private T data;

public static CommonResponseDto success(Object data) {
return CommonResponseDto.builder()
.data(data)
.build();
}


public static CommonResponseDto fail(String errorCode) {
return CommonResponseDto.builder()
.errorCode(errorCode)
.build();
}
}

0 comments on commit 06382b3

Please sign in to comment.