Welcome to mirror list, hosted at ThFree Co, Russian Federation.

dev.gajim.org/gajim/python-nbxmpp.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/nbxmpp
diff options
context:
space:
mode:
authorlovetox <philipp@hoerist.com>2020-10-12 22:03:58 +0300
committerlovetox <philipp@hoerist.com>2020-10-12 23:00:10 +0300
commitaceef5cd9e9477f0442f02678a4b97a4c48ac0ec (patch)
treea49a18fe26caad2e519ca96fa5adb3150f8a6c8c /nbxmpp
parent37aff3c46839caf6eca6e56ea0a61e2a3f742b99 (diff)
Protocol: Add buildSimpleReply()
Diffstat (limited to 'nbxmpp')
-rw-r--r--nbxmpp/protocol.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/nbxmpp/protocol.py b/nbxmpp/protocol.py
index 83575e9..8f0cd99 100644
--- a/nbxmpp/protocol.py
+++ b/nbxmpp/protocol.py
@@ -1571,6 +1571,12 @@ class Iq(Protocol):
iq.setQuery(self.getQuery().getName()).setNamespace(self.getQueryNS())
return iq
+ def buildSimpleReply(self, typ):
+ return Iq(typ,
+ to=self.getFrom(),
+ attrs={'id': self.getID()})
+
+
class Hashes(Node):
"""
Hash elements for various XEPs as defined in XEP-300