Hi,
trying to export Orthanc configuration to remote server with LUA :
function Initialize() local conf = GetOrthancConfiguration() SetHttpCredentials('username', 'password') local result = HttpPost('/my/server/uri', DumpJson(conf)) PrintRecursive(result) end
orthanc log shows following line for each boolean value in orthanc config, and config is received by server with null value for all boolean values (true or false) :
LuaContext.cpp:502] Unsupported Lua type when returning Json
In orthanc config files, boolean values are well formatted. For example :
`
“HttpServerEnabled” : true,
`
In fact, in LuaContext.cpp boolean values are treated as boolean only if keepStrings parameter is false, but orthanc documentation says :
Setting the optional argument
keepStrings
totrue
prevents the automatic conversion of strings to integers.
Boolean are neither strings nor integers, so why are they concerned by this ? BTW it seems that lua_isstring function don’t work with integers, so they should always be treated as integers, no ?
Marc