def _update_children(nodes):
    """ Fills the children property of joints.
    
    :param nodes: Dictionary with skeleton hierarchy.
    :type nodes: dict
    """
    for node, properties in nodes.items():
        parent = properties['parent']
        try:
            p_props = nodes[parent]
        except KeyError:
            if not parent:
                continue
            raise ValueError(
                'ERROR: Parent of {} cannot be found in the hierarchy definition!'
                .format(node))
        p_children = p_props['children']
        p_children.append(node)
        p_props.update({'children': p_children})
