finished spider function