Skip to content

Commit

Permalink
refactor: verifiedArea setter 제거 (#59)
Browse files Browse the repository at this point in the history
  • Loading branch information
gahyuun committed Jan 23, 2025
1 parent 7e4776b commit 16f2d73
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -133,9 +133,7 @@ public String createMemberArea(
optionalVerifiedAreaEntity.ifPresentOrElse(
verifiedAreaEntity -> {
VerifiedArea verifiedArea = verifiedAreaMapper.toDomain(verifiedAreaEntity);
List<LocalDate> dates = verifiedArea.getVerifiedDate();
dates.add(LocalDate.now());
verifiedArea.setVerifiedDate(dates);
verifiedArea.updateVerifiedDate(LocalDate.now());
verifiedAreaRepository.save(verifiedAreaMapper.toEntity(verifiedArea));
},
() -> verifiedAreaRepository.save(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,9 @@
import java.util.List;
import lombok.Builder;
import lombok.Getter;
import lombok.Setter;
import lombok.ToString;

@Getter
@Setter
@ToString
public class VerifiedArea {

Expand Down Expand Up @@ -36,4 +34,8 @@ public VerifiedArea(
this.certifiedForThreeMonths = certifiedForThreeMonths;
this.hasCertificationMark = hasCertificationMark;
}

public void updateVerifiedDate(LocalDate localDate) {
verifiedDate.add(localDate);
}
}

0 comments on commit 16f2d73

Please sign in to comment.