public BestStoriesService(IHackerNewsHttpClient httpClient, ICacheService cache, IOptions <ApiSettings> settings) { this.httpClient = httpClient ?? throw new ArgumentNullException(nameof(httpClient)); this.cache = cache ?? throw new ArgumentNullException(nameof(cache)); this.settings = settings.Value ?? throw new ArgumentNullException(nameof(settings)); }
public HackerNews(IHackerNewsHttpClient client, IMemoryCache cache) { _client = client; _cache = cache; }