summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'Swiften/Serializer/StanzaSerializer.cpp')
-rw-r--r--Swiften/Serializer/StanzaSerializer.cpp8
1 files changed, 6 insertions, 2 deletions
diff --git a/Swiften/Serializer/StanzaSerializer.cpp b/Swiften/Serializer/StanzaSerializer.cpp
index 9a4fd2c..b5f0b22 100644
--- a/Swiften/Serializer/StanzaSerializer.cpp
+++ b/Swiften/Serializer/StanzaSerializer.cpp
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2010 Remko Tronçon
+ * Copyright (c) 2010-2014 Remko Tronçon
* Licensed under the GNU General Public License v3.
* See Documentation/Licenses/GPLv3.txt for more information.
*/
@@ -23,9 +23,13 @@ StanzaSerializer::StanzaSerializer(const std::string& tag, PayloadSerializerColl
}
SafeByteArray StanzaSerializer::serialize(boost::shared_ptr<Element> element) const {
+ return serialize(element, "");
+}
+
+SafeByteArray StanzaSerializer::serialize(boost::shared_ptr<Element> element, const std::string& xmlns) const {
boost::shared_ptr<Stanza> stanza(boost::dynamic_pointer_cast<Stanza>(element));
- XMLElement stanzaElement(tag_);
+ XMLElement stanzaElement(tag_, xmlns);
if (stanza->getFrom().isValid()) {
stanzaElement.setAttribute("from", stanza->getFrom());
}