File tree Expand file tree Collapse file tree
src/main/java/flipnote/group Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -35,29 +35,4 @@ public Group findById(Long id) {
3535 );
3636 return GroupMapper .toDomain (groupEntity );
3737 }
38-
39- /**
40- * 그룹 수정
41- * @param group
42- */
43- @ Override
44- public Group update (Group group ) {
45-
46- GroupEntity groupEntity = groupRepository .findById (group .getId ()).orElseThrow (
47- () -> new IllegalArgumentException ("group not Exist" )
48- );
49-
50- groupEntity .change (
51- group .getName (),
52- group .getCategory (),
53- group .getDescription (),
54- group .getJoinPolicy (),
55- group .getVisibility (),
56- group .getMaxMember (),
57- group .getImageRefId ()
58- );
59-
60- return GroupMapper .toDomain (groupEntity );
61- }
62-
6338}
Original file line number Diff line number Diff line change @@ -6,6 +6,4 @@ public interface GroupRepositoryPort {
66 Long saveNewGroup (Group group );
77
88 Group findById (Long id );
9-
10- Group update (Group group );
119}
Original file line number Diff line number Diff line change @@ -27,11 +27,7 @@ public class FindGroupService implements FindGroupUseCase {
2727 @ Override
2828 public FindGroupResult findGroup (FindGroupCommand cmd ) {
2929
30- GroupEntity groupEntity = groupRepository .findById (cmd .groupId ()).orElseThrow (
31- () -> new IllegalArgumentException ("Group not Exists" )
32- );
33-
34- Group group = GroupMapper .toDomain (groupEntity );
30+ Group group = groupRepository .findById (cmd .groupId ());
3531
3632 return new FindGroupResult (group );
3733 }
You can’t perform that action at this time.
0 commit comments