RESOLVED INVALID 26800
isAncestorNode and isDescendantNode: Confusing function names
https://bugs.webkit.org/show_bug.cgi?id=26800
Summary isAncestorNode and isDescendantNode: Confusing function names
Adam Comella
Reported 2009-06-29 08:59:51 PDT
function isAncestorNode(ancestor) It would seem that this function checks to see if "ancestor" is an ancestor of "this." However, it checks if "ancestor" is a descendant of "this." To clarify the meaning of the function, the function should be renamed to isAncestorNodeOf and the parameter should be renamed to potentialDescendant like this: function isAncestorNodeOf(potentialDescendant) Similar changes should be made to the isDescendantNode function: function isDescendantNodeOf(potentialAncestor)
Attachments
Note You need to log in before you can comment on or make changes to this bug.