14 lines
322 B
Plaintext
14 lines
322 B
Plaintext
///hasChild(parent, id)
|
|
/**
|
|
* hasChild :: TreeNode -> TreeNode -> Boolean
|
|
*
|
|
* Returns whether `parent` directly contains `id` as a child.
|
|
*
|
|
* @param parent the parent TreeNode
|
|
* @param id the child TreeNode
|
|
* @returns true if id is a child of parent
|
|
*/
|
|
|
|
return ds_list_find_index(argument0.children, argument1);
|
|
|