Jsonutils: pass opt for object in object (#16615)
* jsonutils: fromJson forward opt param fix * jsonutils: object in object test + fix: opt pass
This commit is contained in:
parent
d34d023da1
commit
04b765c16d
2 changed files with 7 additions and 1 deletions
|
|
@ -119,7 +119,7 @@ template fromJsonFields(newObj, oldObj, json, discKeys, opt) =
|
|||
when key notin discKeys:
|
||||
if json.hasKey key:
|
||||
numMatched.inc
|
||||
fromJson(val, json[key])
|
||||
fromJson(val, json[key], opt)
|
||||
elif opt.allowMissingKeys:
|
||||
# if there are no discriminant keys the `oldObj` must always have the
|
||||
# same keys as the new one. Otherwise we must check, because they could
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue