diff options
Diffstat (limited to 'Swiften/Serializer/PayloadSerializers/PubSubRetractSerializer.cpp')
-rw-r--r-- | Swiften/Serializer/PayloadSerializers/PubSubRetractSerializer.cpp | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/Swiften/Serializer/PayloadSerializers/PubSubRetractSerializer.cpp b/Swiften/Serializer/PayloadSerializers/PubSubRetractSerializer.cpp index 2d5af7a..9a84959 100644 --- a/Swiften/Serializer/PayloadSerializers/PubSubRetractSerializer.cpp +++ b/Swiften/Serializer/PayloadSerializers/PubSubRetractSerializer.cpp @@ -24,16 +24,16 @@ PubSubRetractSerializer::~PubSubRetractSerializer() { } std::string PubSubRetractSerializer::serializePayload(boost::shared_ptr<PubSubRetract> payload) const { - if (!payload) { - return ""; - } - XMLElement element("retract", "http://jabber.org/protocol/pubsub"); - element.setAttribute("node", payload->getNode()); - foreach(boost::shared_ptr<PubSubItem> item, payload->getItems()) { - element.addNode(boost::make_shared<XMLRawTextNode>(PubSubItemSerializer(serializers).serialize(item))); - } - element.setAttribute("notify", payload->isNotify() ? "true" : "false"); - return element.serialize(); + if (!payload) { + return ""; + } + XMLElement element("retract", "http://jabber.org/protocol/pubsub"); + element.setAttribute("node", payload->getNode()); + foreach(boost::shared_ptr<PubSubItem> item, payload->getItems()) { + element.addNode(boost::make_shared<XMLRawTextNode>(PubSubItemSerializer(serializers).serialize(item))); + } + element.setAttribute("notify", payload->isNotify() ? "true" : "false"); + return element.serialize(); } |