From afbff00c14136e9c110ed597078be4e35c368140 Mon Sep 17 00:00:00 2001 From: Madhur Garg Date: Tue, 13 Aug 2019 14:59:51 +0530 Subject: As per the current structure of slix, reverse parameter takes the value of before tag, so changed it's value from 'true' to the stanza id. --- poezio/mam.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/poezio/mam.py b/poezio/mam.py index c8f095ae..5bc33a4c 100644 --- a/poezio/mam.py +++ b/poezio/mam.py @@ -56,13 +56,13 @@ async def query(tab, remote_jid, top, start=None, end=None, before=None): except (IqError, IqTimeout): return tab.information('Failed to retrieve messages', 'Error') if 'urn:xmpp:mam:2' not in iq['disco_info'].get_features(): - return tab.core.information("%s doesn't support MAM." % remote_jid, "Error") + return tab.core.information("%s doesn't support MAM." % remote_jid, "Info") if top: if isinstance(tab, tabs.MucTab): try: if before is not None: results = tab.core.xmpp['xep_0313'].retrieve(jid=remote_jid, - iterator=True, reverse=top, before=before) + iterator=True, reverse=before, rsm={'before':before}) else: results = tab.core.xmpp['xep_0313'].retrieve(jid=remote_jid, iterator=True, reverse=top, end=end) @@ -72,7 +72,7 @@ async def query(tab, remote_jid, top, start=None, end=None, before=None): try: if before is not None: results = tab.core.xmpp['xep_0313'].retrieve(with_jid=remote_jid, - iterator=True, reverse=top, before=before) + iterator=True, reverse=before, rsm={'before':before}) else: results = tab.core.xmpp['xep_0313'].retrieve(with_jid=remote_jid, iterator=True, reverse=top, end=end) -- cgit v1.2.3