code: func (n *Node) Objectify() interface{} {
  	n.mtx.RLock()
  	defer n.mtx.RUnlock()
  
  	if n.isNil() {
  		return nil
  	}
  
  	if n.Value != nil {
  		return n.Value
  	}
  
  	if n.sliceKids {
  		obj := make([]interface{}, len(n.Children))
  		for k, v := range n.Children {
  			index, err := strconv.Atoi(k)
  			if err != nil {
  				continue
  			}
  			obj[index] = v.Objectify()
  		}
  		return obj
  	}
  
  	obj := map[string]interface{}{}
  	for k, v := range n.Children {
  		obj[k] = v.Objectify()
  	}
  
  	return obj
  }
docs: // Objectify turns the node and all its children into a go type.
  // If a node was created from a slice initially, a slice will be return.
  // If a node has child nodes, a map will be returned.
  // Otherwise, a primitive type will be returned.