Use get_post_ancestors() instead of _get_post_ancestors()