1

restore things lost in merge ffs

This commit is contained in:
Christoph
2020-03-10 13:34:19 +01:00
parent c7d5e02f0b
commit 73e7737b8c
4 changed files with 33 additions and 25 deletions

View File

@ -2,6 +2,7 @@ package mops.gruppen2.service;
import mops.gruppen2.domain.Exceptions.EventException;
import mops.gruppen2.domain.Group;
import mops.gruppen2.domain.event.CreateGroupEvent;
import mops.gruppen2.domain.event.Event;
import org.springframework.stereotype.Service;
@ -29,4 +30,16 @@ public class GroupService {
return newGroup;
}
public Group buildGroupFromEvent(CreateGroupEvent createGroupEvent) {
Group newGroup = new Group();
try {
newGroup.applyEvent(createGroupEvent);
} catch (EventException e) {
e.printStackTrace();
}
return newGroup;
}
}