Refactor scrape_team