diff options
Diffstat (limited to 'Sluift/ElementConvertors/PubSubEventRetractConvertor.cpp')
-rw-r--r-- | Sluift/ElementConvertors/PubSubEventRetractConvertor.cpp | 32 |
1 files changed, 16 insertions, 16 deletions
diff --git a/Sluift/ElementConvertors/PubSubEventRetractConvertor.cpp b/Sluift/ElementConvertors/PubSubEventRetractConvertor.cpp index f851306..15eec91 100644 --- a/Sluift/ElementConvertors/PubSubEventRetractConvertor.cpp +++ b/Sluift/ElementConvertors/PubSubEventRetractConvertor.cpp @@ -13,32 +13,32 @@ using namespace Swift; PubSubEventRetractConvertor::PubSubEventRetractConvertor() : - GenericLuaElementConvertor<PubSubEventRetract>("pubsub_event_retract") { + GenericLuaElementConvertor<PubSubEventRetract>("pubsub_event_retract") { } PubSubEventRetractConvertor::~PubSubEventRetractConvertor() { } boost::shared_ptr<PubSubEventRetract> PubSubEventRetractConvertor::doConvertFromLua(lua_State* L) { - boost::shared_ptr<PubSubEventRetract> result = boost::make_shared<PubSubEventRetract>(); - lua_getfield(L, -1, "id"); - if (lua_isstring(L, -1)) { - result->setID(std::string(lua_tostring(L, -1))); - } - lua_pop(L, 1); - return result; + boost::shared_ptr<PubSubEventRetract> result = boost::make_shared<PubSubEventRetract>(); + lua_getfield(L, -1, "id"); + if (lua_isstring(L, -1)) { + result->setID(std::string(lua_tostring(L, -1))); + } + lua_pop(L, 1); + return result; } void PubSubEventRetractConvertor::doConvertToLua(lua_State* L, boost::shared_ptr<PubSubEventRetract> payload) { - lua_createtable(L, 0, 0); - lua_pushstring(L, payload->getID().c_str()); - lua_setfield(L, -2, "id"); + lua_createtable(L, 0, 0); + lua_pushstring(L, payload->getID().c_str()); + lua_setfield(L, -2, "id"); } boost::optional<LuaElementConvertor::Documentation> PubSubEventRetractConvertor::getDocumentation() const { - return Documentation( - "PubSubEventRetract", - "This table has the following fields:\n\n" - "- `id`: string\n" - ); + return Documentation( + "PubSubEventRetract", + "This table has the following fields:\n\n" + "- `id`: string\n" + ); } |