def get_visible_pages(request, pages, site=None):
 pages = get_visible_page_objects(request, pages, site)
 return [page.pk for page in pages]

def get_visible_pages ( request , pages , site = None ) : pages = get_visible_page_objects ( request , pages , site ) return [ page . pk for page in pages ]
returns the ids of all visible pages .