I have logged in to yahoo messenger as yahoo_1 and i am logged to yahoo_2 from my code using smack and openfire and kraken.
Now from yahoo messenger (yahoo_1) i am adding yahoo_2 so a subscription type packet is comming to my packet listener and i am accepting the request by doing the following:-
- roster.createEntry(yahoo_1, yahoo_1, new String[] { groupName } );
- Presence response = new Presence(Presence.Type.unsubscribed);
- response.setTo(yahoo_1);
- connection.sendPacket(response);
Now after accepting i found that four friend requests are comming to yahoo messenger of yahoo_1. I mean 4 friend request window is openning in my yahoo messenger saying that yahoo_2 want to add you.
- am i doing anything wrong?
- am i missing any important step?
- is there any way to set subscription type =“both”?
- i dont want that a friend request will come to yahoo_1 but inly to yahoo_2 in my code
Regards,
Samba