edit crawl function