aboutsummaryrefslogtreecommitdiff
path: root/xmpp-vala/src/module/xep/0030_service_discovery
diff options
context:
space:
mode:
Diffstat (limited to 'xmpp-vala/src/module/xep/0030_service_discovery')
-rw-r--r--xmpp-vala/src/module/xep/0030_service_discovery/info_result.vala7
1 files changed, 6 insertions, 1 deletions
diff --git a/xmpp-vala/src/module/xep/0030_service_discovery/info_result.vala b/xmpp-vala/src/module/xep/0030_service_discovery/info_result.vala
index dc7f1e48..65252261 100644
--- a/xmpp-vala/src/module/xep/0030_service_discovery/info_result.vala
+++ b/xmpp-vala/src/module/xep/0030_service_discovery/info_result.vala
@@ -39,7 +39,12 @@ public class InfoResult {
public InfoResult(Iq.Stanza iq_request) {
iq = new Iq.Stanza.result(iq_request);
- iq.stanza.put_node(new StanzaNode.build("query", NS_URI_INFO).add_self_xmlns());
+ string? node = iq_request.stanza.get_subnode("query", NS_URI_INFO).get_attribute("node");
+ StanzaNode query = new StanzaNode.build("query", NS_URI_INFO).add_self_xmlns();
+ if (node != null) {
+ query.set_attribute("node", node);
+ }
+ iq.stanza.put_node(query);
}
private InfoResult.from_iq(Iq.Stanza iq) {