Skip to content

Commit 5e66d65

Browse files
committed
fix: ActionChange null 들어오면 모든 필드 null값으로 채움
1 parent 0f2f8bf commit 5e66d65

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/main/java/com/example/wini/domain/log/dto/response/SimpleActionChange.java

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,9 @@
22

33
public record SimpleActionChange(String text, Long monthlyChange) {
44
public static SimpleActionChange from(ActionChange actionChange) {
5+
if (actionChange == null) {
6+
return new SimpleActionChange(null, null);
7+
}
58
return new SimpleActionChange(actionChange.action().getText(), actionChange.monthlyChange());
69
}
710
}

0 commit comments

Comments
 (0)