diff --git a/src/main/java/com/HHive/hhive/domain/user/dto/UserInfoResponseDTO.java b/src/main/java/com/HHive/hhive/domain/user/dto/UserInfoResponseDTO.java index 0a637dc..8abc27c 100644 --- a/src/main/java/com/HHive/hhive/domain/user/dto/UserInfoResponseDTO.java +++ b/src/main/java/com/HHive/hhive/domain/user/dto/UserInfoResponseDTO.java @@ -14,6 +14,7 @@ public class UserInfoResponseDTO { private String description; private String majorCategory; private String subCategory; + private boolean emailVerified; public UserInfoResponseDTO(User user) { this.userId = user.getId(); @@ -27,5 +28,7 @@ public UserInfoResponseDTO(User user) { if (user.getSubCategory() != null) { this.subCategory = user.getSubCategory().name(); } + + this.emailVerified = user.isEmailVerified(); } } diff --git a/src/main/java/com/HHive/hhive/domain/user/entity/User.java b/src/main/java/com/HHive/hhive/domain/user/entity/User.java index 46a332d..c0ff4e9 100644 --- a/src/main/java/com/HHive/hhive/domain/user/entity/User.java +++ b/src/main/java/com/HHive/hhive/domain/user/entity/User.java @@ -54,11 +54,11 @@ public class User extends BaseTimeEntity { // 이메일 인증 여부 필드 추가 @Column(nullable = false) - private boolean email_verified = false; + private boolean emailVerified = false; // 이메일 인증 코드 필드 추가 @Column - private String email_verification_code; + private String emailVerificationCode; public User(String username, String password, String email, String description) { this.username = username; @@ -104,16 +104,16 @@ public void setSubCategory(SubCategory subCategory) { // 이메일 인증 상태를 업데이트하는 메서드 추가 public void setEmailVerified(boolean emailVerified) { - this.email_verified = emailVerified; + this.emailVerified = emailVerified; } // 이메일 인증 코드를 업데이트하는 메서드 추가 public void setEmailVerificationCode(String emailVerificationCode) { - this.email_verification_code = emailVerificationCode; + this.emailVerificationCode = emailVerificationCode; } // 이메일 인증 코드를 가져오는 메서드 추가 public String getEmailVerificationCode() { - return this.email_verification_code; + return this.emailVerificationCode; } }