Question

I m developing android chat app using asmack api with quickblox.

I'm facing problem that in peer to peer chat, i also receive 3rd user chat message in my peer chat.

Any hint or help is appreciated.

Thanks

Was it helpful?

Solution

In the OnMessageReceivedListener check for message received id

String messageString = message.getBody();
  String test=message.getFrom();
  if((friendID+"/Smack").equals(message.getFrom()))
  {

  }

where friend-ID is the id , to which you are connected.

OTHER TIPS

You have to check to which user this message and filter if this message from other users, but not from you current opponent

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top