diff options
author | mathieui <mathieui@mathieui.net> | 2021-03-09 19:15:27 +0100 |
---|---|---|
committer | mathieui <mathieui@mathieui.net> | 2021-03-09 19:52:53 +0100 |
commit | e329eadbedf3dada89f3e7fd5e2bf5d24e995f27 (patch) | |
tree | d64922d39f462963478a10fa6aabbb68a8e71a93 /slixmpp/plugins/xep_0313/mam.py | |
parent | 4cdcc4d155d1bd11afb6366f2b5efa1739788d01 (diff) | |
download | slixmpp-e329eadbedf3dada89f3e7fd5e2bf5d24e995f27.tar.gz slixmpp-e329eadbedf3dada89f3e7fd5e2bf5d24e995f27.tar.bz2 slixmpp-e329eadbedf3dada89f3e7fd5e2bf5d24e995f27.tar.xz slixmpp-e329eadbedf3dada89f3e7fd5e2bf5d24e995f27.zip |
XEP-0313: Fix off-by-one-page RSM fetching
Add a "results" interface to mam_fin, and fix some things in RSM
Items just received were not taken into account because:
- RSM code is checking iq['mam_fin']['results'], results were at
iq['mam']['results']
- RSM handler was run after checking the number
Diffstat (limited to 'slixmpp/plugins/xep_0313/mam.py')
-rw-r--r-- | slixmpp/plugins/xep_0313/mam.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/slixmpp/plugins/xep_0313/mam.py b/slixmpp/plugins/xep_0313/mam.py index c06360c4..cc3b1958 100644 --- a/slixmpp/plugins/xep_0313/mam.py +++ b/slixmpp/plugins/xep_0313/mam.py @@ -112,6 +112,7 @@ class XEP_0313(BasePlugin): results = cb_data['collector'].stop() if result['type'] == 'result': result['mam']['results'] = results + result['mam_fin']['results'] = results if iterator: return self.xmpp['xep_0059'].iterate( @@ -185,6 +186,7 @@ class XEP_0313(BasePlugin): results = cb_data['collector'].stop() if result['type'] == 'result': result['mam']['results'] = results + result['mam_fin']['results'] = results iterator = self.xmpp['xep_0059'].iterate( iq, 'mam', 'results', amount=amount, |