updated scrape code