Extracted into local variable

Co-authored-by: delvh <dev.lh@web.de>
This commit is contained in:
DieGurke 2020-07-08 13:55:19 +02:00 committed by GitHub
parent 71c7d6344b
commit 4a7ad7e1fd
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -45,10 +45,11 @@ public class GroupMessageStatusChangeProcessor implements ObjectProcessor<GroupM
gmsg.setLastStatusChangeDate(LocalDateTime.now());
// Notifying the other members about the status change
final var userID = connectionManager.getUserIDBySocketID(socketID);
gmsg.getMemberMessageStatus()
.keySet()
.stream()
.filter(k -> connectionManager.getUserIDBySocketID(socketID) != k)
.filter(k -> userID != k)
.filter(connectionManager::isOnline)
.forEach(k -> writeProxy.write(connectionManager.getSocketID(k), statusChange));