public async Task Load(string content) { try { var car = JsonConvert.DeserializeObject <CarEntity>(content); _context.Add <CarEntity>(car); await _context.SaveChangesAsync(); } catch (Exception e) { var x = "error"; } }
public async Task Load(string content) { try { var car = JsonConvert.DeserializeObject <CarEntity>(content); _context.Add <CarEntity>(car); await _context.SaveChangesAsync(); } catch { _logger.Log("Error while parsing or save to database for one item."); } }