Add a couple words to docs
This commit is contained in:
parent
6d3fbf973f
commit
4ff5112803
1 changed files with 1 additions and 1 deletions
|
|
@ -635,7 +635,7 @@ proc `[]`*(node: PJsonNode, name: string, default: PJsonNode = nil): PJsonNode =
|
||||||
## foo["field1"]["field2"]
|
## foo["field1"]["field2"]
|
||||||
##
|
##
|
||||||
## If `field1` is undefined, it will return nil, and the access on `field2` will
|
## If `field1` is undefined, it will return nil, and the access on `field2` will
|
||||||
## pass through. Also returns default if the key is not found.
|
## pass through and return nil. Also returns default if the key is not found.
|
||||||
if isNil(node):
|
if isNil(node):
|
||||||
return default
|
return default
|
||||||
assert(node.kind == JObject)
|
assert(node.kind == JObject)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue