Software /
code /
prosody
Comparison
plugins/muc/hats.lib.lua @ 13523:365212120b82
MUC: Fix error with nonlegacy hats.
author | Aidan Epstein <aidan@jmad.org> |
---|---|
date | Sat, 28 Sep 2024 12:38:42 -0700 |
parent | 13469:f9171624fd03 |
child | 13692:18bc411d61fe |
comparison
equal
deleted
inserted
replaced
13522:ccd6199cc6a2 | 13523:365212120b82 |
---|---|
23 hats_el = st.stanza("hats", { xmlns = xmlns_hats }); | 23 hats_el = st.stanza("hats", { xmlns = xmlns_hats }); |
24 end | 24 end |
25 hats_el:tag("hat", { uri = hat_id, title = hat_data.title }):up(); | 25 hats_el:tag("hat", { uri = hat_id, title = hat_data.title }):up(); |
26 | 26 |
27 if hats_compat then | 27 if hats_compat then |
28 if not hats_el then | 28 if not legacy_hats_el then |
29 legacy_hats_el = st.stanza("hats", { xmlns = xmlns_hats_legacy }); | 29 legacy_hats_el = st.stanza("hats", { xmlns = xmlns_hats_legacy }); |
30 end | 30 end |
31 legacy_hats_el:tag("hat", { uri = hat_id, title = hat_data.title }):up(); | 31 legacy_hats_el:tag("hat", { uri = hat_id, title = hat_data.title }):up(); |
32 end | 32 end |
33 end | 33 end |