         assert _.isObject(value), "authority isn't dictionary"
         authority = @_from_dict(value)
         @put(AUTHORITY, authority)
-      else if key == CHILDREN
+      else if key == CHILDREN and !_.isFunction(value)
         for child in value
           assert child, 'import child'
           @add_child child

    child
    
  find_children: (label) ->
    return @get(CHILDREN).all() unless label?
    result = []
    for child in @get(CHILDREN).all()
      result.push child if child.label() == label
    result
    
  find_child: (label) ->
    @find_children(label)[0]

  has_children: ->
    @get(CHILDREN).length() > 0
    
  map_children: (callback) ->
    result = @rx().array()
    for child in @get(CHILDREN).all()
      result.push callback(child)
    result
  

    return @_from_dict(value) if isObject(value)
    @_from_value value
    
  _children: -> @get(CHILDREN)
  _child_array: -> @_children().all()
  _child_count: -> @_children().length()
  has_children: -> @_child_count() > 0
    
  add_child: (value) ->
    child = @make_world value
    assert child, "add_child"
