#69 changed isCurrentUserParticipant

This commit is contained in:
Nightblade73 2019-04-19 14:29:08 +04:00
parent 713e50043e
commit 9edcebb2f5

View File

@ -134,11 +134,6 @@ public class ConferenceService {
public boolean isCurrentUserParticipant(List<ConferenceUser> conferenceUsers) {
for (ConferenceUser participant : conferenceUsers) {
if (participant.getUser().getId() == userService.getCurrentUser().getId()) {
return true;
}
}
return false;
return conferenceUsers.stream().anyMatch(participant -> participant.getUser().equals(userService.getCurrentUser()));
}
}