public IActionResult Index() { #if DEBUG _sitesRepo.Truncate(); #endif var sites = _configuration.GetSection("Init").Get <string[]>(); foreach (var site in sites) { _sitesRepo.Create(new Sites() { Url = site }); } ViewBag.RefreshTime = Convert.ToInt32(_configuration["RefreshTime"]); return(View(_sitesRepo.Get().ToList())); }