Skip to content

Commit

Permalink
[refactor] Mission에서 NotNull 제약조건 추가 및 default value 추가 (#401)
Browse files Browse the repository at this point in the history
  • Loading branch information
kseysh committed Oct 8, 2024
1 parent 62fe08d commit 3b6456a
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/main/java/org/sopt/app/domain/entity/Notification.java
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,11 @@ public class Notification extends BaseEntity{
@Column(name = "notification_title", columnDefinition = "TEXT")
private String title;

@NotNull
@Column(name = "notification_content", columnDefinition = "TEXT")
private String content;

@NotNull
@Column(name = "notification_type")
@Enumerated(EnumType.STRING)
private NotificationType type;
Expand All @@ -48,7 +50,7 @@ public class Notification extends BaseEntity{

@NotNull
@ColumnDefault("false")
private Boolean isRead;
private boolean isRead;

public void updateIsRead() {
this.isRead = true;
Expand Down

0 comments on commit 3b6456a

Please sign in to comment.