* lisp/org.el (org-in-archived-heading-p): Do not check for point position when ELEMENT is provided and use ELEMENT when checking archive status of ancestors.