public async Task <T> Remove(T Item) { await Task.FromResult(_dbContext.Remove <T>(Item)); await _dbContext.SaveChangesAsync(); return(Item); }
private void RemoveExistingCheckouts(int deviceId) { var checkout = _context.Checkouts.FirstOrDefault(ch => ch.Device.Id == deviceId); if (checkout != null) { _context.Remove(checkout); } }