diff options
author | Sebastien Douheret <sebastien.douheret@iot.bzh> | 2017-08-22 18:19:36 +0200 |
---|---|---|
committer | Sebastien Douheret <sebastien.douheret@iot.bzh> | 2017-08-22 18:19:36 +0200 |
commit | 1d7c537cb1106f8daf36a6bbd69ecd377b542b39 (patch) | |
tree | b1884d6e2f175df198520735aabdec9cfecff4aa /Controller-afb | |
parent | 0ed9fae2e8a8ce564b0aa09770a850c4bb3605db (diff) |
Fixed Lua Table to Json parsing
Signed-off-by: Sebastien Douheret <sebastien.douheret@iot.bzh>
Diffstat (limited to 'Controller-afb')
-rw-r--r-- | Controller-afb/ctl-lua.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Controller-afb/ctl-lua.c b/Controller-afb/ctl-lua.c index ce631dc..8d5a87e 100644 --- a/Controller-afb/ctl-lua.c +++ b/Controller-afb/ctl-lua.c @@ -199,8 +199,8 @@ STATIC json_object *LuaTableToJson (lua_State* luaState, int index) { if (!tableJ) { tableJ= json_object_new_array(); tableType=LUA_TNUMBER; - } else if(tableType == LUA_TNUMBER) { - AFB_ERROR("MIX Lua Table with key string/numeric not supported"); + } else if(tableType != LUA_TNUMBER) { + AFB_ERROR("MIX Lua Table with key numeric/string not supported"); return NULL; } |