refactored rotten tomatoes api calls