Mercurial > prosody-hg
diff util/stanza.lua @ 10443:f28718f46196
util.stanza: Remove redundant check for attrs
A stanza can't not have attrs if created the correct way
| author | Kim Alvefur <zash@zash.se> |
|---|---|
| date | Mon, 25 Nov 2019 20:46:55 +0100 |
| parents | 22db763c510c |
| children | 4eab1f5a4f3b |
line wrap: on
line diff
--- a/util/stanza.lua Mon Nov 25 20:44:05 2019 +0100 +++ b/util/stanza.lua Mon Nov 25 20:46:55 2019 +0100 @@ -438,7 +438,7 @@ error("bad argument to reply: expected stanza, got "..type(orig)); end return new_stanza(orig.name, - orig.attr and { + { to = orig.attr.from, from = orig.attr.to, id = orig.attr.id,
