Fix LogPlain parsing

This commit is contained in:
Gabriel Tofvesson 2024-10-26 19:45:58 +02:00
parent 569a4370c0
commit b5fd24740b

View File

@ -105,9 +105,9 @@ function RecursionSentinel.remove(knownTables, value)
end end
local function cloneNonRecursive(inValue, sentinels) local function cloneNonRecursive(inValue, sentinels)
if type(inValue) == "table" then local value = LogPlain.getValue(inValue)
if type(value) == "table" then
local wrapLogPlain = LogPlain.is(inValue) and function(v) return LogPlain.of(v, inValue.deep) end or function(v) return v end local wrapLogPlain = LogPlain.is(inValue) and function(v) return LogPlain.of(v, inValue.deep) end or function(v) return v end
local value = LogPlain.getValue(inValue)
if RecursionSentinel.isKnown(sentinels, value) then if RecursionSentinel.isKnown(sentinels, value) then
return wrapLogPlain(RecursionSentinel.getSentinel(sentinels, value)) return wrapLogPlain(RecursionSentinel.getSentinel(sentinels, value))
end end