aksonov / react-native-xmpp

XMPP library for React Native (iOS and Android native support)

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Chat History In Android

chins25 opened this issue · comments

Hi,

I have implemented chat with Smack 4.1.0 for React Native.I am sending a following stanza for Android,

<iq id="downloadMessages" type="get"> <query xmlns="urn:xmpp:mam:tmp"> <with>user1@serverdomain.com</with> <set xmlns="http://jabber.org/protocol/rsm"/> </query> </iq>

and, I am receiving following data,

{"from":"MyUser@serverdomain.com","body":null,"src":"<message to='MyUser@serverdomain.com/3fb36b4ca0a5c' from='MyUser@serverdomain.com'><thread>ThreadID</thread><result xmlns='urn:xmpp:mam:tmp'><archived></archived><request></request><delay></delay><stanza-id></stanza-id><active></active><body>My MESSAGE</body></result></message>","subject":null,"thread":"ThreadId"}

When I get a chat history, I do not get the JID and I get only my JID for all messages. SO , in this case I am unable to get the name of the person (JID) with whom I have chatted.
Any help will be appreciated.

FYI for IOS it is working fine .