public async Task <JsonResult> GetStoresAsync() { IEnumerable <Store> stores = null; try { stores = await _parsingService.GetAndTransformStores(); await _vetDirectoryService.InsertStoresAsync(stores.ToList()); } catch (Exception ex) { _logger.LogError(ex.Message); return(Json(data: ex.Message)); } return(Json(new { redirectUrl = Url.Action("StoreDetails", "Home"), isRedirect = true })); }