Adjusted to event system refactoring
This commit is contained in:
parent
31c80492df
commit
4909a65464
@ -5,6 +5,7 @@ import java.util.stream.Collectors;
|
||||
|
||||
import envoy.data.Contacts;
|
||||
import envoy.event.ContactSearchRequest;
|
||||
import envoy.event.ContactSearchResult;
|
||||
import envoy.server.ConnectionManager;
|
||||
import envoy.server.ObjectProcessor;
|
||||
import envoy.server.data.User;
|
||||
@ -32,7 +33,7 @@ public class ContactsRequestEventProcessor implements ObjectProcessor<ContactSea
|
||||
@Override
|
||||
public void process(ContactSearchRequest request, long socketId, ObjectWriteProxy writeProxy) throws IOException {
|
||||
writeProxy.write(socketId,
|
||||
new Contacts(PersistenceManager.getPersistenceManager()
|
||||
new ContactSearchResult(PersistenceManager.getPersistenceManager()
|
||||
.searchUsers(request.get(), ConnectionManager.getInstance().getUserIdBySocketId(socketId))
|
||||
.stream()
|
||||
.map(User::toCommonUser)
|
||||
|
Reference in New Issue
Block a user