changeset 3617:766729ac4146

plugin XEP-0059: don't show warning message when <last> is missing if there is not message
author Goffi <goffi@goffi.org>
date Mon, 02 Aug 2021 21:52:17 +0200
parents 59d6d4afebf2
children 7f503b20597e
files sat/plugins/plugin_xep_0059.py
diffstat 1 files changed, 2 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/sat/plugins/plugin_xep_0059.py	Mon Aug 02 21:51:55 2021 +0200
+++ b/sat/plugins/plugin_xep_0059.py	Mon Aug 02 21:52:17 2021 +0200
@@ -138,7 +138,8 @@
                 )
 
         if rsm_response.last is None:
-            log.warning("Can't do pagination, no \"last\" received")
+            if rsm_response.count:
+                log.warning("Can't do pagination, no \"last\" received")
             return None
 
         return rsm.RSMRequest(