updated scraper to handle new terms gracefully
cleaned up get_term function