aboutsummaryrefslogtreecommitdiffstats
path: root/util/xmppstream.lua
diff options
context:
space:
mode:
Diffstat (limited to 'util/xmppstream.lua')
-rw-r--r--util/xmppstream.lua3
1 files changed, 2 insertions, 1 deletions
diff --git a/util/xmppstream.lua b/util/xmppstream.lua
index 0a6d554b..29095e41 100644
--- a/util/xmppstream.lua
+++ b/util/xmppstream.lua
@@ -117,7 +117,8 @@ function new_sax_handlers(session, stream_callbacks)
chardata = {};
end
-- Complete stanza
- if #stanza.last_add == 0 then
+ local last_add = stanza.last_add;
+ if not last_add or #last_add == 0 then
if tagname ~= stream_error_tag then
cb_handlestanza(session, stanza);
else